uv
Install
sudo pacman -S uv
Usage
Initialize in existing project (creates .python-version
, pyproject.toml
. hello.py
):
uv init --no-workspace .
Add a dependency (creates virtualenv at: .venv
):
uv add "ansible<10"
Add requirements from a requirements.txt
file:
uv add -r requirements.txt
Update lockfile when i.e. adding dependencies manually to pyproject.toml
:
uv lock
Install dependencies:
uv sync
venv
To run a cmd inside the venv:
uv run ansible