REPOMATIC-PRUNE-CACHES(1) REPOMATIC-PRUNE-CACHES(1)

repomatic prune-caches - Delete the superseded GitHub Actions caches of a key prefix

repomatic prune-caches [OPTIONS]

Delete the GitHub Actions caches a newer save superseded.

A cache step keyed on the run or the commit, with a prefix in its restore-keys, saves a fresh entry on every run and restores the newest previous one. Every older entry is dead weight against the 10 GB quota of the repository until GitHub evicts it, and past the quota GitHub evicts live caches too. This deletes all but the newest --keep entries of each --prefix. Run it after the restore step of the job that saves: the job's own save then adds one more entry.

Needs `actions: write` on the token. A refused deletion and an unreadable listing are reported as warnings: housekeeping never fails the job it runs in.

Key prefix whose caches to prune, as the step's restore-keys names it. Repeatable.
[required]
Newest caches of each prefix to leave in place.
Repository in owner/repo format. Defaults to $GITHUB_REPOSITORY, then to the GitHub remote of the current clone.
Report what would be done without making changes.
Show this message and exit.

Key prefix whose caches to prune, as the step's restore-keys names it. Repeatable.
Newest caches of each prefix to leave in place.
Repository in owner/repo format. Defaults to $GITHUB_REPOSITORY, then to the GitHub remote of the current clone.
Repository in owner/repo format. Defaults to $GITHUB_REPOSITORY, then to the GitHub remote of the current clone.
Report what would be done without making changes.
Show this message and exit.

0
Success.
1
A runtime error, an aborted prompt (Ctrl-D), or a declined confirmation.
2
A usage error: unknown option, invalid value, missing operand, or an unparsable configuration file.
130
Interrupted with Ctrl-C: the process ends by SIGINT, reported as 130.

Preview what a prune of the Linux compile caches would delete

repomatic prune\-caches \-\-dry\-run \-\-prefix nuitka\-linux\-x64\-

Keep the two newest HTTP caches of each runner, as the sync jobs do

repomatic prune\-caches \-\-keep 2 \-\-prefix repomatic\-http\-Linux\-

Kevin Deldycke

2026-10-29 8.0.1.dev0