Skip to content

Instantly share code, notes, and snippets.

@EJSohn
Last active October 10, 2018 15:06
Show Gist options
  • Select an option

  • Save EJSohn/ac78c209342b117e224602aa272afa42 to your computer and use it in GitHub Desktop.

Select an option

Save EJSohn/ac78c209342b117e224602aa272afa42 to your computer and use it in GitHub Desktop.
bash script install pyenv&virtualenv in ubuntu.
# install ubuntu packages
apt-get install -y make build-essential libssl-dev zlib1g-dev libbz2-dev \
libreadline-dev libsqlite3-dev wget curl llvm libncurses5-dev libncursesw5-dev \
xz-utils tk-dev
touch ~/.bash_profile
# install pyenv
git clone https://github.com/pyenv/pyenv.git ~/.pyenv
echo 'export PYENV_ROOT="$HOME/.pyenv"' >> ~/.bash_profile
echo 'export PATH="$PYENV_ROOT/bin:$PATH"' >> ~/.bash_profile
echo 'eval "$(pyenv init - --no-rehash)"' >> ~/.bash_profile
# install virtualenv
git clone https://github.com/yyuu/pyenv-virtualenv.git ~/.pyenv/plugins/pyenv-virtualenv
echo 'eval "$(pyenv virtualenv-init -)"' >> ~/.bash_profile
source ~/.bash_profile
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment