Mastering Python Virtual Environments with Pipenv
O
Ohidur Rahman Bappy
MAR 22, 2025
Pipenv Cheat Sheet
Install Pipenv
pip3 install pipenv
Activate the Environment
pipenv shell
Check Python Version
python --version
Verify Python Path
python
>>> import sys
>>> sys.executable
quit()
Install a Package
pipenv install camelcase
List Local Packages
pipenv lock -r
Uninstall a Package
pipenv uninstall camelcase
Install a Development Package
pipenv install nose --dev
Install from requirements.txt
pipenv install -r ./requirements.txt
Check for Security Vulnerabilities
pipenv check
View Dependency Graph
pipenv graph
Ignore Pipfile During Install
pipenv install --ignore-pipfile
Lock Dependencies Before Deployment
pipenv lock
Exiting the Virtual Environment
exit
Run a Script with Pipenv
pipenv run *