Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SHELL

linux set python 3 as default

1. Check current version:
$ python --version
2. get root permissions:
$ sudo su
3. set python3 as default:
$ update-alternatives --install /usr/bin/python python /usr/bin/python3 1
4. Done. (Check by $ python --version)
Source by unix.stackexchange.com #
 
PREVIOUS NEXT
Tagged: #linux #set #python #default
ADD COMMENT
Topic
Name
1+5 =