# uv

`cooldown` gates uv projects through `--tool uv` (aliases `pypi`, `python`).

## What it reads

A uv project is a `pyproject.toml` with its `uv.lock`.

## Registry

Every package is judged by its PyPI release, whichever index serves it.

uv's native cooldown is `exclude-newer`.
[`cooldown sync`](https://romnn.github.io/cooldown/docs/commands/other/#uv) writes the resolved policy into the
repository's `uv.toml` as `exclude-newer` and `exclude-newer-package`.

## How it is driven

`cooldown` runs `uv`, or the program `COOLDOWN_UV` names. Every uv command it runs passes the
project's resolved policy as `--exclude-newer` and `--exclude-newer-package` arguments, whatever
the configuration files say:

- **`check`:** proves the lock current with `uv lock --check`.
- **`upgrade` and `fix`:** re-lock with `uv lock`.
- **`--build`:** runs `uv sync`.

uv and Poetry both own `pyproject.toml`, so at one root they take turns under `upgrade`, `fix` and
`--lock`; see [Several ecosystems at once](https://romnn.github.io/cooldown/docs/tools/#several-ecosystems-at-once).
