How to Install Pyenv Virtualenv on Ubuntu 18.04

July 8, 2020 Liquid Web

Pyenv is an outstanding tool for managing multiple Python installations. Pyenv-virtualenv is a pyenv plugin that facilitates the creation and management of Python virtual environments with pyenv. This is a compelling proposition, making it possible to manage multiple Python versions with pyenv and provide the means to control the Python environment in a more granular manner.

In this video, we describe how to Install Pyenv Virtualenv on an Ubuntu 18.04 server.

Commands used:
apt update -y
git clone https://github.com/pyenv/pyenv-virtualenv.git $(pyenv root)/plugins/pyenv-virtualenv
echo 'eval "$(pyenv virtualenv-init -)"' >> ~/.bashrc
exec "$SHELL"
mkdir python_project
cd python_project/
pyenv-virtualenv <python-version> <virtual-environment-name>
pyenv versions
pyenv virtualenv 3.8.3 python-project-3.8.3
pyenv versions
pyenv local python-project-3.8.3
cd
cd python_project/
cd
pyenv activate python-project-3.8.3
pyenv deactivate

Video by: Justin Palmer

About the Author

Liquid Web

Liquid Web powers online content, commerce, and potential for SMB entrepreneurs and the designers, developers and digital agencies who create for them. Sign up for our newsletter to stay up to date with our latest content.

More Content by Liquid Web
Previous Video
How to Install MySQL on Windows
How to Install MySQL on Windows

In this video, we describe how to install MySQL on Windows.

Next Video
Modifying Fields in Database Tables Using PhpMyAdmin
Modifying Fields in Database Tables Using PhpMyAdmin

In this video, we describe how to modify fields in a database table via PhpMyAdmin.

Learn What Qualities to Look for in Your Next Host in Our New Guide!

Download Now