- Check if
curl
is installed:
curl --version
If it is not installed, install as follows:
sudo apt-get install curl
- Install
pyenv
:
curl https://pyenv.run | bash
- Update
~/.bashrc
with the following information:
export PATH="~/.pyenv/bin:$PATH"
eval "$(pyenv init -)"
eval "$(pyenv virtualenv-init -)"
- Restart your shell so the path changes can take effect:
exec $SHELL
To update pyenv
:
pyenv update
To uninstall pyenv
:
rm -rf ~/.pyenv
Remove the added entries from ~./bashrc
export PATH="$HOME/.pyenv/bin:$PATH"
eval "$(pyenv init --path)"
eval "$(pyenv virtualenv-init -)"
Restart shell
exec $SHELL