Close sprint
Agent OS is a management layer for complex, multi-agent AI projects. Instead of letting agents get lost in endless conversational loops, it enforces a disciplined workflow: upfront planning, shared context, scoped work tracks, and strict quality gates — so every agent stays focused, coordinated, and aligned from start to finish.
npx -y skills add designgrappler/agent-os --skill close-sprintAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
One thing to look at
- 1 stars1 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.
What its author says it does
Copied from the file, not written here
Closes the current sprint — verifies all tracks are resolved, runs the build, bumps the version, archives the plan, and resets context files.
SKILL.md
7.5 KB, as published. Nobody here has run it
Instructions
Step 1 — Close any completed-but-not-yet-closed tracks
Read docs/context/tracks.md. For each track belonging to the current sprint:
-
Work complete, exit record not yet written (OPEN with completed work): invoke
/track-close <track-id> "<outcome>"to write the exit record. Do not write the exit record inline —/track-closeis the sole mechanism for writing DONE exit records. -
Explicitly deferred: record a DEFERRED note in the track's exit record manually (deferral is not a DONE close;
/track-closeonly writes DONE). -
Still OPEN or BLOCKED with no completed work: surface the list and stop:
The following tracks are not yet resolved: [list]. Resolve or explicitly defer each before closing the sprint.
Wait for confirmation before continuing.
Step 1b — Backlog audit
After all tracks are confirmed DONE, scan docs/backlog.md for items that correspond to work completed in this sprint.
Match on: items explicitly tagged with the track ID (e.g. (T53.1)), or items whose title closely matches a completed track description.
If matches found: surface them to the user:
"The following backlog items appear to correspond to completed work this sprint. Remove them?
- [item title]" Wait for confirmation before removing.
If no matches found: skip silently. Do not mention this step in output.
Removal: if confirmed, remove the matched line(s) from docs/backlog.md. Do not remove section headers or surrounding items.
Step 2 — Run build
Run bun run build. If it fails, surface the error and stop. Do not continue until the build passes.
Step 3 — Bump version in skills-manifest.json
Read skills-manifest.json and determine the appropriate version bump:
- Patch — bug fixes, copy corrections, non-behavioral edits only
- Minor — new skills, new agents, or new features added this sprint
- Major — breaking changes that require manual user action
Increment "release-version" accordingly (e.g. "v0.20.0" → "v0.20.1" for patch, "v0.21.0" for minor). Write the updated value back to skills-manifest.json.
Step 4 — Plan doc archival (rolling window)
Plan doc archival (rolling window): Move docs/temp-sprint<N>-plan.md to docs/archive/plan-docs/S<N>.md. Then check docs/archive/plan-docs/ — delete any entries older than the 3-sprint window (keep current sprint + 2 prior). Git history retains all older content.
After moving the plan doc, stage the deletion so it does not appear as an uncommitted change:
git rm docs/temp-sprint<N>-plan.md
Then scan for any other docs/temp-<sprint-scoped>-*.md files whose name contains the sprint number (e.g. docs/temp-s<N>-*.md). For each found, run:
git rm <file>
Log each additional file removed. This catches spike docs, test results, editorial notes, and other sprint-scoped temp artifacts.
If docs/archive/plan-docs/ does not exist, create it silently before moving.
Step 5 — Archive the sprint plan
Read docs/context/plan.md and locate the ## Current Sprint: S<N> section. Copy its full content (all headings, goals, and notes under it) to docs/archive/plan-docs/S<N>.md if the file does not already exist from Step 4.
Step 6 — Reset context files
docs/context/plan.md: Replace the current sprint section with a single archived pointer line:
## Completed Sprint: S<N> ✓ — see docs/archive/plan-docs/S<N>.md
Preserve all prior completed sprint pointer lines below it.
docs/context/tracks.md: Replace all track entries for the closed sprint with the same single pointer line:
## Completed Sprint: S<N> ✓ — see docs/archive/plan-docs/S<N>.md
Preserve any tracks from other sprints.
Step 7 — Commit sprint close
Stage and commit the version bump, archive file, and context reset:
git add skills-manifest.json docs/archive/plan-docs/S<N>.md docs/context/plan.md docs/context/tracks.md
git commit -m "chore(S<N>): sprint close — <new-version>, archive plan, reset context"
Step 7b — Merged worktree sweep
After the sprint close commit, sweep merged worktrees:
- For each directory under
.claude/worktrees/:- Get the branch:
git -C <repo-root> -C <path> branch --show-current - Check if merged:
git -C <repo-root> branch --merged main | grep <branch> - If merged:
git -C <repo-root> worktree remove <path>and logremoved worktree: <path> (branch: <branch>) - If not merged or branch state ambiguous: log
skipped: <path> (not merged)— do not remove
- Get the branch:
- Delete all merged
worktree-agent-*branches:git -C <repo-root> branch --merged main | grep worktree-agent- | xargs git -C <repo-root> branch -d - Log total removed count.
Note: use git -C <repo-root> form for all git commands in this step, where <repo-root> is the project root directory. This avoids the shell loop git-not-in-PATH issue that affects subshell environments.
Step 8 — Create GitHub release and push
Before creating the release, derive the release notes from the sprint archive doc at docs/archive/plan-docs/S<N>.md. Use the "What changed" section (or equivalent) as the release body. Do not use a fallback string — if the archive doc is missing or has no substantive content, stop and ask the user for release notes before proceeding.
gh release create <new-version> \
--repo designgrappler/agent-os-private \
--title "<new-version>" \
--notes "<release notes from archive doc>"
git push
git fetch origin <new-version>
Note: gh release create pushes the tag to the remote. git fetch origin <new-version> syncs it locally. Do not run git push origin <new-version> — the tag already exists on the remote after gh release create.
Step 9 — Run /clean-context
After the push succeeds, invoke /clean-context. This sweeps bridge files, merged worktrees, merged branches, and scratchpads automatically as the final act of sprint close.
/clean-context runs its own safety check (uncommitted work, dirty worktrees) and will bail with a warning if anything is unresolved — surface any bail messages to the user and do not proceed to Step 10 until the issue is resolved.
Step 10 — Confirm
Output a short confirmation:
Sprint S<N> closed.
Version bumped to: <new-version>
Archive: docs/archive/plan-docs/S<N>.md
plan.md and tracks.md reset.
GitHub release: https://github.com/designgrappler/agent-os-private/releases/tag/<new-version>
/clean-context: complete
Verification checklist
- All tracks for the closed sprint have DONE or DEFERRED exit records before Step 2 ran.
bun run buildpassed.skills-manifest.jsonversion bumped to the correct next version.- Sprint plan doc archived to
docs/archive/plan-docs/S<N>.md. docs/context/plan.mdcurrent sprint block collapsed to a single pointer line.docs/context/tracks.mdsprint block collapsed to a single pointer line.- Sprint close commit created with the correct message format.
- Merged worktrees swept (Step 7b): merged ones removed, non-merged ones logged.
- GitHub release created;
git pushandgit fetch origin <new-version>ran without error. /clean-contextinvoked after push and completed without bail (or bail message surfaced to user if it fired).