ngit-grasp cleanup-empty-repos
Remove kind 30617/30618 events whose bare git repository is empty or missing
Upcoming operator surface
This page is generated from an unreleased ngit-grasp commit. Its interface may change before the next release.
Parent command: ngit-grasp
Usage
text
Usage: ngit-grasp cleanup-empty-repos [OPTIONS]Arguments and options
| Input | Description | Details |
|---|---|---|
--relay-data-path <RELAY_DATA_PATH> | Path to the LMDB relay data directory (contains the nostr event database). Defaults to ./data/relay (same default as the relay itself). | env NGIT_RELAY_DATA_PATH; default ./data/relay |
--git-data-path <GIT_DATA_PATH> | Path to the git data directory (contains bare repositories). Defaults to ./data/git (same default as the relay itself). | env NGIT_GIT_DATA_PATH; default ./data/git |
--execute | Actually delete empty repositories and remove their events from the database. Without this flag the command runs in dry-run mode and only prints what would be deleted. Stop the relay service before using this flag. | — |
--purge-orphans | Also purge non-empty orphan git repos (repos on disk with no matching 30617 event). By default, non-empty orphan repos are flagged but not deleted. Pass this flag together with --execute to permanently delete them. Use with caution. | — |
-h, --help | Print help (see a summary with '-h') | — |
-V, --version | Print version | — |
Details
Remove kind 30617/30618 events whose bare git repository is empty or missing.
Runs in dry-run mode by default. Pass --execute to make changes. Stop the relay service before running with --execute.
Related reference
Flags backed by environment variables are also listed in the configuration reference.