- First create a virtual environment
python -m venv .venv
- Activate the virtual environment
source .venv/bin/activate
- Install pip-tools
pip install pip-tools
- Resolve project dependencies
pip-compile -o requirements.txt pyproject.toml
- Optional dev dependencies
pip-compile --extra dev -o dev-requirements.txt pyproject.toml
- Install dependencies
pip install -r requirements.txt
pip install -r dev-requirements.txt