This is an opinionated route towards python management. Every computer may have its own set up.
Level 0: “I just want to play with python”
Method 1: Use and online REPL like this: https://repl.it/languages/python
Level 1: “I want python on my computer”
Download brew
, use brew
to download the latest version of python and go crazy.
$ brew install python
Level 2: “I want to manage python packages for a project”
Use virtualenv
to create virtually separated environments for each of your projects. Make sure to “freeze” your requirements to a file so you record every version number of every downloaded package. You can pip install virtualenv
to download this library.
(Optional): use virtualenv-wrapper
to manage all the virtualenv
‘s you will eventually create
Level 3: “I need to manage python versions now”
Use pyenv
to manage python versions per project and check this into version control. pyenv
uses a .python-version
file in your project to determine which python to use for the project.
virtualenv
can still be used to manage package versions
Optional: use pyenv-virtualenv
which is a pyenv
plugin to “automate” the creation of virtualenv
‘s