all that is technology

Python Pipenv quick start guide for managing packages and virtualenv


In this video I'm going to show you how to start using pipenv for your python projects.

Pipenv is a packaging tool which automatically creates and manages virtualenv and packages.

# To create a new virtual environment
$ mkdir pipenv-demo && cd pipenv-demo
$ pipenv shell
(venv) $ cat Pipfile

# To install a package and add to Pipfile
(venv) $ pipenv install flask

# To install a dev package
(venv) $ pipenv install pytest --dev

# To install all packages from Pipfile
(venv) $ pipenv install

# To install all packages including dev-packages
(venv) $ pipenv install --dev

# To show the dependency graph
(venv) $ pipenv graph

# To uninstall a package and remove from Pipfile
(venv) $ pipenv uninstall pytest

Hope this helps!