save-statelisted
Install: claude install-skill shck-dev/ccx-context-system
# Save state — the single-pane work index
This regenerates the scratch INDEX, the one screen that shows everything in flight. **Pull, don't
copy:** the index is a thin layer of pointers + live status; the real detail stays in each thread's
STATE doc. Never hand-maintain the INDEX — re-run this skill.
## Live data (injected at load — already current below)
**Project + config:**
!`bun "${CLAUDE_PLUGIN_ROOT}/scripts/where.ts"`
**Branch:** !`git rev-parse --abbrev-ref HEAD 2>/dev/null || echo "(not a git repo)"`
**Worktrees (parallel work):**
!`git worktree list 2>/dev/null || echo "(none)"`
**Recent commits:**
!`git log --oneline -8 2>/dev/null || echo "(no git history)"`
**Uncommitted (working tree):**
!`git status --short 2>/dev/null | head -15`
**Scratch threads:**
!`bun "${CLAUDE_PLUGIN_ROOT}/scripts/threads.ts"`
**Notes missing a graph backlink (orphan risk — each should open with a wikilink to its STATE):**
!`bun "${CLAUDE_PLUGIN_ROOT}/scripts/orphans.ts"`
**Open PRs:**
!`gh pr list --limit 12 2>/dev/null || echo "(gh unavailable / not a GitHub repo)"`
## Then do this
1. **Refresh each active thread's STATE frontmatter** so its INDEX line is right. The INDEX is a
pure render of these fields — stale frontmatter = stale dashboard:
- `kind:` — `thread` (in-flight) · `hub` (permanent reference note) · `done` (shipped / prune
candidate).
- `summary:` — the single-line INDEX blurb (the **live working-state**, not just the title);
YAML-quote it `sum