-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathcommands.sh
More file actions
47 lines (34 loc) · 928 Bytes
/
commands.sh
File metadata and controls
47 lines (34 loc) · 928 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
# What versions I have
pyenv versions
# Install new version
# 1. See what versions we have
pyenv install --list | grep 3.9
# 2. Install new version
pyenv install 3.9.0
# Crete new project dir
mkdir debugdemo
cd debugdemo
# Make my shell use version 3.9.0 instead of system python
pyenv local 3.9.0
# OR alternatively
echo "3.9.0" > .python-version
# Check that we are on correct version
python --version
# See what venv can do
python -m venv --help
# Create virtual environment
python -m venv .venv
# Activate virtual env
source .venv/bin/activate
# Install required packages
pip install debugpy black ipython
# Save our list of dependencies as requirements
pip freeze > requirements.txt
# (Note) Hot to install dependencies from requirements file
pip install -r requirements.txt
# How to remove dependency using pip
pip uninstll debugpy
# Deactivate environment
deactivate
# Delete virtual environment
rm -rf .venv