Skip to content

Instantly share code, notes, and snippets.

@jonathanhle
Forked from styk-tv/ubu22 pyenv
Created September 5, 2022 02:28
Show Gist options
  • Save jonathanhle/5455c59bfb62a0abec841e610d44ef0f to your computer and use it in GitHub Desktop.
Save jonathanhle/5455c59bfb62a0abec841e610d44ef0f to your computer and use it in GitHub Desktop.
Install pyenv on Ubuntu
#!/bin/bash
sudo apt-get install git python-pip make build-essential libssl-dev zlib1g-dev libbz2-dev libreadline-dev libsqlite3-dev curl
sudo pip install virtualenvwrapper
git clone https://github.com/yyuu/pyenv.git ~/.pyenv
git clone https://github.com/yyuu/pyenv-virtualenvwrapper.git ~/.pyenv/plugins/pyenv-virtualenvwrapper
git clone https://github.com/pyenv/pyenv-virtualenv.git ~/.pyenv/plugins/pyenv-virtualenv
echo 'export PYENV_ROOT="$HOME/.pyenv"' >> ~/.bashrc
echo 'export PATH="$PYENV_ROOT/bin:$PATH"' >> ~/.bashrc
echo 'eval "$(pyenv init -)"' >> ~/.bashrc
echo 'pyenv virtualenvwrapper' >> ~/.bashrc
exec $SHELL
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment