UV Package Manager¶
UV is a fast Python package manager that provides efficient dependency management. This guide covers how to set up and use UV in the Py Launch Blueprint project.
Installation¶
To install UV, run:
pip install uv
Alternatively, this project’s root Makefile provides convenient targets for installing and force-installing uv:
make install-uv
make install-uv-force
Refer to the Makefiles documentation for more details on these make commands, especially if you prefer a project-standardized installation method or encounter issues with other methods.
Using UV for Dependency Management¶
Installing Dependencies¶
To install dependencies from pyproject.toml, use:
uv pip install -r requirements.txt
Or, if using pyproject.toml:
uv pip install
Adding a Package¶
To install a package and add it to your dependencies:
uv pip install <package-name>
Removing a Package¶
To uninstall a package:
uv pip uninstall <package-name>
Creating a Lockfile¶
To generate a lockfile (requirements.lock), run:
uv pip freeze > requirements.lock
Additional Resources¶
For more details, check the official UV documentation.