← ClaudeAtlas

undo-bootstraplisted

Reverse a bootstrap or retrofit run by walking its BootRecord manifest: restore pre-state files, drop branches that were created, surface anything that couldn't be safely undone. TRIGGER when the user says "undo the bootstrap", "undo nyann setup", "revert nyann setup", "uninstall nyann from this repo", "back out the bootstrap", "undo the retrofit", "I regret running bootstrap", "rip out nyann", "/nyann:undo-bootstrap". ALSO trigger when the user wants to roll back a /nyann:retrofit run that drifted things they didn't expect — retrofit remediation goes through bootstrap.sh, so its boot record is in the same place. DISAMBIGUATION: this is NOT `/nyann:undo` — that one rewinds git commits on a feature branch via `git reset`, completely separate from filesystem mutations bootstrap made. If the user just said "undo my last commit", route to `/nyann:undo` instead. Do NOT trigger on "uninstall the plugin" — that's a Claude Code plugin manager concern, not a per-repo undo. Do NOT trigger on "remove .git" / "delete the
thettwe/nyann · ★ 6 · Code & Development · score 71
Install: claude install-skill thettwe/nyann
# undo-bootstrap Wraps `bin/undo-bootstrap.sh`. Read this end-to-end before invoking; the refusal modes carry real meaning. ## 1. Locate the BootRecord Boot records live under `<repo>/memory/.nyann/bootstraps/<ISO-ts>/`. Each contains a `manifest.json` (the BootRecord) and a `pre-state/` directory with original file bytes. By default the script picks the newest manifest. When the repo has multiple records (typical: one bootstrap + one or more retrofits), **list them and ask** which to undo: ```bash ls -1t memory/.nyann/bootstraps/*/manifest.json | head -10 ``` Show the list with `created_at`, `source`, and a one-line summary (extract via `jq -r '.created_at + " " + .source + " (" + (.actions | length | tostring) + " actions)"'`). Pass the chosen one via `--manifest <path>`. ## 2. Always preview first Run with `--dry-run` and surface the JSON to the user: ```bash bin/undo-bootstrap.sh --target "$PWD" --dry-run ``` Walk the four arrays in the result: `restored`, `deleted`, `branches_dropped`, `defaults_renamed_back`. Read `skipped[]` carefully and explain each entry — they're the load-bearing communication. For ambiguous cases (skipped entries with overrides available), **use `AskUserQuestion`**: ```json { "questions": [ { "question": "Some files were modified after bootstrap finished. Override and overwrite local edits?", "header": "Force", "multiSelect": false, "options": [ { "label": "No (Recommended)", "description": "Skip