Created
October 20, 2021 15:46
-
-
Save 0scvr/06daec38c43f340347a02f84827ec90c to your computer and use it in GitHub Desktop.
Python venv commands
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# create a virtual environment named env by convention | |
python3 -m venv env | |
# make sure to add env/ (or whatever you named your virtual environment) to your .gitignore file | |
# use the virtual environment | |
source env/bin/activate | |
# save dependencies to requirements.txt file | |
pip freeze > requirements.txt | |
# exit the virtual environment | |
deactive |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment