Installing Python 2 on Linux
Note
Check out our guide for installing Python 3 on Linux.
The latest versions of CentOS, Red Hat Enterprise Linux (RHEL) and Ubuntucome with Python 2.7 out of the box.
To see which version of Python you have installed, open a command prompt and run
However, with the growing popularity of Python 3, some distributions, such asFedora, don’t come with Python 2 pre-installed. You can install the package with your distribution package manager:
The two most crucial third-party Python packages are and pip.
Once installed, you can download, install and uninstall any compliant Python softwareproduct with a single command. It also enables you to add this network installationcapability to your own Python software with very little work.
Python 2.7.9 and later (on the python2 series), and Python 3.4 and later includepip by default.
To see if pip is installed, open a command prompt and run
To install pip, - this will automatically install the latest version of setuptools.
Virtual Environments
For example, you can work on a project which requires Django 1.10 while alsomaintaining a project which requires Django 1.8.
To start using this and see more information: docs.
You can also use virtualenvwrapper to make it easier tomanage your virtual environments.
This page is a remixed version of ,which is available under the same license.