[PYTHON] pyenv memo

environment

install & check folder

$ brew install pyenv
$ cd ~/.pyenv

you can also install by git

list packages and install python3.6.7 python3.6.8

$ pyenv install -l
$ pyenv install 3.6.7 3.6.8
$ pyenv versions
* system(set by /Users/xxxx/.python-version)
  3.6.7
  3.6.8  

create virtual environment

pyenv virtualenv python_version environment_name
$ pyenv virtualenv 3.6.7 environ_3.6.7
$ pyenv versions
  system
  3.6.7
  3.6.7/envs/environ_3.6.7
  environ_3.6.7
  ...

delete virtual environment

$ pyenv uninstall environ_3.6.7
$ pyenv versions
  system
  3.6.7
  ...

change global python version

pyenv global python_version[or python_virtual_environment]
$ pyenv global environ_3.6.7
(environ_3.6.7) xxxxxx:~ user$ 
$ python -V
Python 3.6.7
$ cd ~/.pyenv
$ vi version
 environ_3.6.7
if you delete this "version" file, the global python will change to system python

switch to environment

pyenv local python_version[or python_virtual_environment]
$ pyenv local 3.6.8
(3.6.8) xxxxxx:~ user$ 
$ python -V
Python 3.6.8

Recommended Posts

pyenv memo
Raspberry-pi memo
Pandas memo
pyenv note
HackerRank memo
pyenv notes
system-wide pyenv
python memo
graphene memo
Flask memo
Matplotlib memo
pytest memo
sed memo
Python memo
Install Memo
BeautifulSoup4 memo
networkx memo
pyenv summary
Environment construction memo of pyenv + conda
python memo
tomcat memo
command memo
Generator memo.
psycopg2 memo
Python memo
SSH memo
Command memo
Memo: rtl8812
pandas memo
Shell memo
Python memo
Pycharm memo
Python memo
AtCoder devotion memo (11/12)
[OpenCV] Personal memo
[Python] Memo dictionary
PyPI push memo
LPIC201 learning memo
Jupyter Notebook memo
LPIC304 virtualization memo
ALDA execution memo
python beginner memo (9.2-10)
youtube download memo
Linux x memo
Django Learning Memo
LPIC101 study memo
python beginner memo (9.1)
linux (ubuntu) memo
scp command memo
Flask Primer Memo
celery / kombu memo
who command memo
django tutorial memo
Flask basic memo
Linux # Command Memo 1
pyenv + virtualenv + Anaconda
★ Memo ★ Python Iroha
Gender recognition memo
Image reading memo
[Memo] Build a virtual environment with Pyenv + anaconda
pyenv installation notes