gestate
Set a minimum release age on local package managers so installs ignore versions younger than N days. Most malicious packages are caught and yanked within days of publishing; refusing fresh versions blocks the bulk of supply-chain attacks.
Run
uvx gestate # interactive
uvx gestate set 3 # 3-day minimum, installed tools only
uvx gestate set 3 --all # also pre-configure file-based tools (bun, deno, uv)
uvx gestate set 3 --local # write per-project config files in the current repo
uvx gestate revert # remove gestate's settings
uvx gestate revert --local # remove the per-project gate from this repo
uvx gestate explain bun # show how one tool's setting is stored
uvx gestate trust my-pkg --python # exempt a package from the age delay
uvx gestate trust --rm my-pkg # remove an exemption
uvx gestate trust # list trusted packages
Interactive mode always shows a plan and asks for explicit confirmation before touching anything. The subcommands skip the confirm — meant for scripts, not your daily shell. Running with no subcommand outside a TTY exits with an error.
Plain text output is used when stdout isn't a terminal (no Rich tables/colors).
What it sets
| Tool | Where | Key (unit) |
|---|---|---|
| npm | ~/.npmrc |
min-release-age (days) |
| pnpm | global pnpm config | minimumReleaseAge (minutes) |
| yarn | ~/.yarnrc.yml (4.10+) |
npmMinimalAgeGate (minutes) |
| bun | ~/.bunfig.toml |
[install] minimumReleaseAge (seconds) |
| deno | shell profile | alias deno='command deno --minimum-dependency-age=P<N>D' |
| pip | user pip config | global.uploaded-prior-to (P<N>D) |
| uv | ~/.config/uv/uv.toml |
exclude-newer ("N days") |
gestate explain <tool> prints that tool's current value and the exact mechanism set / revert use.
Scope:
- default — only configure installed tools
--all— also pre-write config files forbun,deno,uveven if they aren't installed yet
Project-local policy (--local)
gestate set <days> --local writes each tool's native, committed-to-the-repo config so the gate travels with the project and applies to anyone who clones it — even collaborators who never ran gestate. It only configures tools the repo gives evidence of (a lockfile, manifest, or existing tool config in the current directory), so it won't litter a JS repo with uv.toml or vice versa.
| Tool | Project file (cwd) | Key (unit) |
|---|---|---|
| npm | .npmrc |
min-release-age (days) |
| pnpm | pnpm-workspace.yaml |
minimumReleaseAge (minutes) |
| yarn | .yarnrc.yml |
npmMinimalAgeGate (minutes) |
| bun | bunfig.toml |
[install] minimumReleaseAge (seconds) |
| deno | deno.json |
minimumDependencyAge (P<N>D) |
| uv | uv.toml |
exclude-newer ("N days") |
pip has no per-project config (and no dependency-age gate), so it's skipped. If a deno.json has comments (JSONC), gestate won't rewrite it — it prints the line to add yourself. revert --local removes the key and deletes any file it leaves empty.
Revert
uvx gestate revert removes everything gestate set:
- CLI tools —
config delete/config unset bun/uv— remove the key; delete the file if it was the only keydeno— remove our alias line; leave foreignalias deno=lines alone
Backups (.bak) are written next to any edited shell-profile or TOML file.
Per-package exemptions (trust)
gestate trust lets you exempt specific packages from the age delay so they always get the latest version:
gestate trust @myorg/* # auto-detects Node (scoped package)
gestate trust my-lib --python # exempt in uv
gestate trust --rm my-lib --python # remove exemption
gestate trust # list all trusted packages
gestate trust --python # list Python ecosystem only
The --python / --node flags are optional — gestate auto-detects the ecosystem from scoped packages (@scope/name → Node) or the current directory (pyproject.toml → Python, package.json → Node). When it can't tell, it asks you to specify.
Supported tools: bun, uv, yarn, pnpm, npm (requires npm ≥ 11.17.0). deno and pip don't support per-package allowlists and print a warning. For manual config details, see docs/allowlists.md.
Caveats
- yarn: 4.10+ only. Older yarn is detected and skipped.
- deno: no global config exists; the shell alias only covers interactive shells. For CI, pass
--minimum-dependency-age=P<N>Dtodeno install/deno update, or commit a projectdeno.jsonwith"minimumDependencyAge": "P<N>D". - npm trust: requires npm ≥ 11.17.0. gestate skips npm with a note when the installed npm is older (global scope only — a project
.npmrcis still written, since it's enforced by whoever installs). Early npm releases didn't honormin-release-age-excludeinnpxor every reify path. - pip exclude: none —
global.uploaded-prior-tois global only.
For PR-creation guards (Dependabot, Renovate) and adjacent layers, see docs/complementary.md.
Development
uv sync
uv run pytest
Requires Python 3.11+, macOS or Linux.
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file gestate-1.2.0.tar.gz.
File metadata
- Download URL: gestate-1.2.0.tar.gz
- Upload date:
- Size: 49.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e91f703fd35b042136f62096f981e826603ad8ab7edc790b0204d71a77b70e21
|
|
| MD5 |
a58708e001c4699533dcf87f97f9bc14
|
|
| BLAKE2b-256 |
aa8f16ddd2bfa9913de0af942ea4d8d6acf04eb8b0364aa299339a60385c4466
|
Provenance
The following attestation bundles were made for gestate-1.2.0.tar.gz:
Publisher:
release.yml on lincolnloop/gestate
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
gestate-1.2.0.tar.gz -
Subject digest:
e91f703fd35b042136f62096f981e826603ad8ab7edc790b0204d71a77b70e21 - Sigstore transparency entry: 2337392176
- Sigstore integration time:
-
Permalink:
lincolnloop/gestate@f6a7126024e93a3c17bda7dc88da6ff59202e8f4 -
Branch / Tag:
refs/tags/v1.2.0 - Owner: https://github.com/lincolnloop
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@f6a7126024e93a3c17bda7dc88da6ff59202e8f4 -
Trigger Event:
push
-
Statement type:
File details
Details for the file gestate-1.2.0-py3-none-any.whl.
File metadata
- Download URL: gestate-1.2.0-py3-none-any.whl
- Upload date:
- Size: 21.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
226b41906f46feb04d099d1fdf2d170989af830e29cc6aa33bcfec9e3b219adb
|
|
| MD5 |
80b53063d436069aa8b4ac345b94f788
|
|
| BLAKE2b-256 |
832d2bdb2845a53ed01c89517dd00243053d5bb1b623c3f17ef6b8673c108563
|
Provenance
The following attestation bundles were made for gestate-1.2.0-py3-none-any.whl:
Publisher:
release.yml on lincolnloop/gestate
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
gestate-1.2.0-py3-none-any.whl -
Subject digest:
226b41906f46feb04d099d1fdf2d170989af830e29cc6aa33bcfec9e3b219adb - Sigstore transparency entry: 2337392203
- Sigstore integration time:
-
Permalink:
lincolnloop/gestate@f6a7126024e93a3c17bda7dc88da6ff59202e8f4 -
Branch / Tag:
refs/tags/v1.2.0 - Owner: https://github.com/lincolnloop
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@f6a7126024e93a3c17bda7dc88da6ff59202e8f4 -
Trigger Event:
push
-
Statement type: