πͺ¦ Graveyard
Archive old GitHub repositories into a single private "graveyard" repo as restorable git bundles β then safely delete the originals.
Got a GitHub account cluttered with dead side-projects, abandoned experiments,
and one-off repos you'll "definitely come back to"? Graveyard walks you through
retiring them: it captures each repo's complete history (every branch, tag,
and even pull-request refs) into a single .bundle file, stores them all in one
cheap private repo, and only deletes an original after its backup is verified
present. Nothing is lost, and your repo list gets a lot shorter.
It ships as a Claude Code plugin but works with any coding agent β the
core is plain bash + git + gh, driven by a standard SKILL.md and an
AGENTS.md entry point.
Part of the agent-plugins marketplace.
What it does
- Lists your repos with the details you need to decide (size, last push, fork status, visibility).
- You choose which to retire. Empty repos and forks are flagged β no point bundling those.
- Bundles each chosen repo:
git clone --mirror+git bundle create --allcaptures the full history, then verifies the bundle is valid. - Documents every archive β a per-repo
README.mdwith restore commands plus ametadata.jsonsnapshot, and a top-level index. - Pushes the graveyard to a private GitHub repo and confirms each bundle actually landed.
- Generates a guarded delete script for you to review and run. It re-checks each backup exists on GitHub before deleting the original.
Why git bundles?
A git bundle is a single file of real
git objects β not a zip of the working tree. You can git clone straight from
it, and it preserves the entire history. Mirror-cloning first means the bundle
holds every ref, so a restored repo is indistinguishable from the original.
That fidelity is exactly what makes deleting the original safe.
# Restoring is a one-liner:
git clone my-old-project.bundle my-old-project
Quick start
As a Claude Code plugin
# Add the marketplace, then install:
/plugin marketplace add JRichlen/agent-plugins
/plugin install graveyard@jrichlen
Then just ask, or run the command:
/graveyard
"Help me archive my old GitHub repos into a graveyard and delete them."
With any other agent (Codex, Cursor, Gemini, Aider, β¦)
git clone https://github.com/JRichlen/agent-plugins
cd agent-plugins/plugins/graveyard
Point your agent at AGENTS.md (most read it automatically) and
ask it to archive your old repos. See docs/installation.md
for per-harness setup.
Or run the scripts directly, no agent
# Back up one repo:
skills/graveyard/scripts/archive-repo.sh octocat/Hello-World ./graveyard
# Generate a guarded deletion script:
skills/graveyard/scripts/generate-delete-script.sh octocat graveyard \
--bundled "Hello-World" > delete-originals.sh
Requirements
git- GitHub CLI
gh, authenticated:gh auth login - Deletion needs the
delete_reposcope β the generated script adds it for you interactively (one-time browser step).
Safety model
Deleting a GitHub repo is irreversible, so Graveyard is built around not trusting itself:
- The tool never deletes anything directly. It generates a script you review and run.
- That script re-verifies each bundle exists in the graveyard on GitHub before deleting its original. No backup, no delete.
- Repos deleted without a backup (empty repos, forks) are listed explicitly in the script β nothing is deleted silently.
- The graveyard repo defaults to private, because bundles contain full history including anything ever committed.
These invariants are enforced by the marketplace's eval suite β see
evals/.
Documentation
- Installation β per-harness setup (Claude Code, Codex, Cursor, Gemini, Aider, standalone).
- Usage walkthrough β a full end-to-end example.
- How it works β bundles, mirror clones, the PR-ref detail, and restore mechanics.
Layout
plugins/graveyard/
βββ .claude-plugin/plugin.json # Claude Code plugin manifest
βββ AGENTS.md # cross-harness entry point
βββ commands/graveyard.md # /graveyard slash command
βββ skills/graveyard/
β βββ SKILL.md # the portable workflow (read this)
β βββ scripts/
β βββ archive-repo.sh # bundle one repo (verified)
β βββ generate-delete-script.sh # emit guarded delete script
βββ docs/
βββ README.md
License
MIT β see LICENSE.