#install git
yum install git
#Clone pyenv
git clone https://github.com/pyenv/pyenv.git ~/.pyenv
#Add to environment variable
echo 'export PYENV_ROOT="$HOME/.pyenv"' >> ~/.zshrc
echo 'export PATH="$PYENV_ROOT/bin:$PATH"' >> ~/.zshrc
echo -e 'if command -v pyenv 1>/dev/null 2>&1; then\n eval "$(pyenv init -)"\nfi' >> ~/.zshrc
exec "$SHELL"
#Install dependent software
sudo yum install gcc zlib-devel bzip2 bzip2-devel readline-devel sqlite sqlite-devel openssl-devel tk-devel libffi-devel
pyenv install 3.7.7
Recommended Posts