Install pyenv for the time being
$ git clone https://github.com/yyuu/pyenv.git ~/.pyenv
Install a specific version
$ pyenv install 3.7.3
Create and move the base directory of the quarantine environment
$ mkdir sandbox
$ cd sandbox
Specify local version
$ pyenv local 3.7.3
Create venv environment
$ python -m venv venv
Switch to venv environment
$ source venv/bin/activate
Check which python you are using
$ which python
~/sandbox/venv/bin/python
Recommended Posts