Metadata-Version: 2.4
Name: hestia-keyring
Version: 1.0.0a3
Summary: Keyring backend for HES Azure Artifacts — enables uv sync without PATs
License: MIT
Requires-Python: >=3.13
Requires-Dist: azure-identity>=1.19
Requires-Dist: keyring>=24.0
Description-Content-Type: text/markdown

# hestia-keyring

A [keyring](https://pypi.org/project/keyring/) backend that authenticates `uv sync` against
the HES Azure Artifacts feed using your active `az` CLI session — no Personal Access Tokens
required.

## Install once per machine

```bash
uv tool install keyring --with hestia-keyring
```

## What it does

When `uv` calls `keyring get https://pkgs.dev.azure.com/... VssSessionToken`, this backend
runs `az account get-access-token --resource https://app.vssps.visualstudio.com` and returns
the resulting bearer token. Your `az login` session is the only credential you need.

## Requirements

- Python 3.13+
- [Azure CLI](https://learn.microsoft.com/en-us/cli/azure/install-azure-cli) installed and
  signed in (`az login`)

## Consumer app configuration

Add to your app's `pyproject.toml`:

```toml
[[tool.uv.index]]
name = "hes-internal"
url = "https://VssSessionToken@pkgs.dev.azure.com/<org>/<project>/_packaging/<feed>/pypi/simple/"
default = false
explicit = true

[tool.uv.sources]
hestia = { index = "hes-internal" }

[tool.uv]
keyring-provider = "subprocess"
```

The `VssSessionToken@` prefix in the URL is required — uv passes the URL username to
`keyring get`, and `VssSessionToken` is the username this backend recognises.
