Skip to content

Instantly share code, notes, and snippets.

@suuhm
Created January 9, 2024 16:13
Show Gist options
  • Save suuhm/9aa7e9846e26a2a0c4d76a9f3b3ae071 to your computer and use it in GitHub Desktop.
Save suuhm/9aa7e9846e26a2a0c4d76a9f3b3ae071 to your computer and use it in GitHub Desktop.
PIP update / set virtual enviroment and get requierement.txt and install it
# PIP / VIRTUALENV
# ----------------
python -m pip install --upgrade pip || \
#
apt update && \
apt install python-pip python3-pip python3-virtualenv
# OLD: ( pip install virualenv )
virtualenv [--python=python3] project-XYZ
cd project-XYZ ; source bin/activate
#
# OUT:
# pip list
deactivate
# ---------------------------
pip freeze [--local] > requirements.txt
# INSTALL REQUIREMENTS:
# pip install -r requirements.txt
#
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment