Installation & environment activation
Install Poetry (Linux/WSL. For others, see Poetry docs):
curl -sSL https://install.python-poetry.org | python3 -
Create new project:
poetry new <project-name>
Navigate to project directory:
cd <project-name>
Activate virtual env from directory:
poetry shell
Installing packages
Installing packages:
poetry add <package-name>
From a requirements.txt (more info):
cat requirements.txt | grep -E '^[^# ]' | cut -d= -f1 | xargs -n 1 poetry add
See more useful commands here.
Top comments (0)