Skip to content

Commit 436e565

Browse files
committed
Uses PPA to target specific version.
1 parent 2d760e2 commit 436e565

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

installing-python-linux.md

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,15 +34,19 @@ On different Linux systems, there are a couple of different ways to install and
3434

3535
### Installing with `apt-get` (Ubuntu, Debian)
3636

37-
`apt-get` is Linux's Advanced Package Tool, and is very useful for installing, managing, upgrading, and removing packages on Debian, Ubuntu, and a few other Linux distributions. It looks like `apt-get` doesn't have a Python3.7 package, so you will have to install whatever the latest version of Python is.
37+
`apt-get` is Linux's Advanced Package Tool, and is very useful for installing, managing, upgrading, and removing packages on Debian, Ubuntu, and a few other Linux distributions. We'll use [Felix Krull's PPA](https://launchpad.net/~deadsnakes/+archive/ubuntu/ppa) to install specific Python versions.
3838

3939
```
40-
$ sudo apt-get install python3
40+
$ sudo add-apt-repository ppa:deadsnakes/ppa
41+
$ sudo apt-get update
42+
$ sudo apt-get install python3.7
4143
```
4244

45+
On Debian, we'll just have to `sudo apt-get install python3` and hope for the best. Also note that this might install a different version of Python 3.7 (e.g. Python 3.7.1), but we won't worry about that here.
46+
4347
### Installing with `yum` (RedHat, CentOS)
4448

45-
Other Linux distributions use a different package manager, `yum`. We don't have any test devices with these Linux distributions, so you're on your own here. There is a reasonably good tutorial for CentOS [here](https://www.digitalocean.com/community/tutorials/how-to-install-python-3-and-set-up-a-local-programming-environment-on-centos-7) and
49+
Other Linux distributions use a different package manager, `yum`. We don't have any test devices with these Linux distributions, so you're on your own here. There is a reasonably good tutorial for CentOS [here](https://www.digitalocean.com/community/tutorials/how-to-install-python-3-and-set-up-a-local-programming-environment-on-centos-7).
4650

4751
### Other Linux package managers
4852

0 commit comments

Comments
 (0)