How to install specific version of python?

I remotely login to Linux virtual box from ssh.
I have following python versions installed:
Python 2.7.15+
Python 3.6.8
Python 3.7.3

How do I install Python 2.7.6

https://www.tecmint.com/pyenv-install-and-manage-multiple-python-versions-in-linux/

https://qr.ae/TSLnlU

Will installation of Python 2.7.6 interfere will all current python installations and symlinks. Please see attached.

Just compile it locally, but don’t install it. Then always run this specific python version like this:
(Assuming the directory where you installed this Python version is ~/python.)

~/python/python myScript.py

Though, I recommend making a backup before messing with Python, because Python is the cancer of scripting languages.

1 Like