Session Update / Wrap-Up
Capture everything that happened during the work session so the next session starts with full context. This is the counterpart to /start.
Execution Flow
Phase 1 — Gather Session Activity (run in parallel)
1a. Git Activity
git log --oneline --since="8 hours ago" — commits made this session
git diff --stat — unstaged changes
git diff --cached --stat — staged but uncommitted changes
git stash list — any stashed work
git branch -vv — current branch and tracking status
- Note the current branch name and whether it has unpushed commits.
1b. GitHub Activity (skip gracefully if gh unavailable)
gh pr list --author @me --state open — your open PRs and their CI status
gh pr list --search "reviewed-by:@me" — PRs you reviewed today
- Check if any PRs are ready to merge (approved + CI passing).
1c. Task State
- Read
~/.claude/tasks/TASKS.md if it exists.
- Identify tasks that were
in-progress at session start.
- Cross-reference with git activity to infer which tasks were worked on.
1d. Memory State
- Read
~/.claude/memory/MEMORY.md if it exists.
- Note any memories that may be stale or need updating based on today's work.
Phase 2 — Analyze and Classify
Categorize the session's work:
- Completed: Tasks finished, PRs merged, issues closed.
- Progressed: Tasks/PRs that moved forward but aren't done.
- Created: New branches, PRs, tasks, or issues opened.
- Blocked: Anything that hit a wall — note the specific blocker.
- Discovered: New information, decisions, or context that emerged.
Phase 3 — Update Systems
Update Tasks
For each task that was worked on:
- Update
status if it changed (todo -> in-progress, in-progress -> done).
- Set
updated: {today}.
- Add a timestamped note under
## Notes summarizing progress.
- Set
completed: {today} if done.
- Update
TASKS.md index to reflect current state.
Save New Memories (only if warranted)
Evaluate whether any session context should be persisted. Save only what is:
- Non-obvious (not in code, commits, or task files)
- Useful for future sessions (not just today)
- Decision context ("we chose X because Y" — the "because Y" part)
Do NOT save:
- What code was changed (that's in git)
- Task status updates (that's in task files)
- Anything that will be stale by next session
If saving, follow the /memory-management save protocol.
Flag Uncommitted Work
If there are uncommitted changes:
- Warn the user with the list of modified files.
- Ask if they want to commit, stash, or leave as-is.
- Do NOT commit or stash without explicit confirmation.
Phase 4 — Present Summary
Output a structured wrap-up:
## Session Summary — {date}
### Completed
- Merged PR #123: "Add auth middleware"
- Closed TASK-005: "Migrate user table"
### In Progress
- PR #125: "Add rate limiting" — CI passing, awaiting review
- TASK-008: branch `feature/rate-limit` — 3 uncommitted files
### Blocked
- TASK-006: "Deploy auth service" — waiting on staging environment access
### Decisions & Context Saved
- Saved memory: "Auth service uses JWT with 15min expiry — compliance requirement"
### For Next Session
- Review PR #130 from @teammate (requested 2 days ago)
- TASK-008 needs tests before opening PR
- Merge freeze starts 2026-04-10 — finish open PRs before then
### Uncommitted Work
- `src/middleware/rate-limit.ts` (modified)
- `tests/rate-limit.test.ts` (new)
> Action needed: commit, stash, or leave?
Phase 5 — Handoff
Ask the user:
- "Anything else to capture before wrapping up?"
- If they mention something, save it as a memory or task as appropriate.
- End with a brief "you're all set" confirmation.
Edge Cases
- No activity: If no git commits, task changes, or PR activity, acknowledge a light session. Don't fabricate activity.
- Multiple repos: Only summarize the current working directory. If memories reference other projects, note them under "For Next Session."
- First session: If no task or memory system exists yet, offer to set them up using
/task-management and /memory-management.
- Long sessions: If git log shows > 20 commits, group by branch or feature area rather than listing each one.
Output Standards
- Use the same formatting conventions as
/start for consistency.
- Show dates in relative + absolute form.
- Keep the summary under 50 lines unless the user asks for detail.
- Bold section headers and key action items.
Quality Checklist
1---2name: update3description: End-of-session wrap-up — capture progress, update tasks, save context for next session. TRIGGER when: user says "wrap up", "end of day", "save progress", "update", "done for today", "session summary", or is finishing a work session.4---56# Session Update / Wrap-Up78Capture everything that happened during the work session so the next session starts with full context. This is the counterpart to `/start`.910## Execution Flow1112### Phase 1 — Gather Session Activity (run in parallel)1314#### 1a. Git Activity1516- `git log --oneline --since="8 hours ago"` — commits made this session17- `git diff --stat` — unstaged changes18- `git diff --cached --stat` — staged but uncommitted changes19- `git stash list` — any stashed work20- `git branch -vv` — current branch and tracking status21- Note the current branch name and whether it has unpushed commits.2223#### 1b. GitHub Activity (skip gracefully if `gh` unavailable)2425- `gh pr list --author @me --state open` — your open PRs and their CI status26- `gh pr list --search "reviewed-by:@me"` — PRs you reviewed today27- Check if any PRs are ready to merge (approved + CI passing).2829#### 1c. Task State3031- Read `~/.claude/tasks/TASKS.md` if it exists.32- Identify tasks that were `in-progress` at session start.33- Cross-reference with git activity to infer which tasks were worked on.3435#### 1d. Memory State3637- Read `~/.claude/memory/MEMORY.md` if it exists.38- Note any memories that may be stale or need updating based on today's work.3940### Phase 2 — Analyze and Classify4142Categorize the session's work:43441. **Completed**: Tasks finished, PRs merged, issues closed.452. **Progressed**: Tasks/PRs that moved forward but aren't done.463. **Created**: New branches, PRs, tasks, or issues opened.474. **Blocked**: Anything that hit a wall — note the specific blocker.485. **Discovered**: New information, decisions, or context that emerged.4950### Phase 3 — Update Systems5152#### Update Tasks5354For each task that was worked on:551. Update `status` if it changed (todo -> in-progress, in-progress -> done).562. Set `updated: {today}`.573. Add a timestamped note under `## Notes` summarizing progress.584. Set `completed: {today}` if done.595. Update `TASKS.md` index to reflect current state.6061#### Save New Memories (only if warranted)6263Evaluate whether any session context should be persisted. **Save only what is:**64- Non-obvious (not in code, commits, or task files)65- Useful for future sessions (not just today)66- Decision context ("we chose X because Y" — the "because Y" part)6768**Do NOT save:**69- What code was changed (that's in git)70- Task status updates (that's in task files)71- Anything that will be stale by next session7273If saving, follow the `/memory-management` save protocol.7475#### Flag Uncommitted Work7677If there are uncommitted changes:78- Warn the user with the list of modified files.79- Ask if they want to commit, stash, or leave as-is.80- Do NOT commit or stash without explicit confirmation.8182### Phase 4 — Present Summary8384Output a structured wrap-up:8586```87## Session Summary — {date}8889### Completed90- Merged PR #123: "Add auth middleware"91- Closed TASK-005: "Migrate user table"9293### In Progress94- PR #125: "Add rate limiting" — CI passing, awaiting review95- TASK-008: branch `feature/rate-limit` — 3 uncommitted files9697### Blocked98- TASK-006: "Deploy auth service" — waiting on staging environment access99100### Decisions & Context Saved101- Saved memory: "Auth service uses JWT with 15min expiry — compliance requirement"102103### For Next Session104- Review PR #130 from @teammate (requested 2 days ago)105- TASK-008 needs tests before opening PR106- Merge freeze starts 2026-04-10 — finish open PRs before then107108### Uncommitted Work109- `src/middleware/rate-limit.ts` (modified)110- `tests/rate-limit.test.ts` (new)111> Action needed: commit, stash, or leave?112```113114### Phase 5 — Handoff115116Ask the user:1171181. "Anything else to capture before wrapping up?"1192. If they mention something, save it as a memory or task as appropriate.1203. End with a brief "you're all set" confirmation.121122## Edge Cases123124- **No activity**: If no git commits, task changes, or PR activity, acknowledge a light session. Don't fabricate activity.125- **Multiple repos**: Only summarize the current working directory. If memories reference other projects, note them under "For Next Session."126- **First session**: If no task or memory system exists yet, offer to set them up using `/task-management` and `/memory-management`.127- **Long sessions**: If git log shows > 20 commits, group by branch or feature area rather than listing each one.128129## Output Standards130131- Use the same formatting conventions as `/start` for consistency.132- Show dates in relative + absolute form.133- Keep the summary under 50 lines unless the user asks for detail.134- Bold section headers and key action items.135136## Quality Checklist137138- [ ] Output is specific and actionable, not generic139- [ ] All relevant inputs have been gathered before producing output140- [ ] Recommendations are prioritized by impact141- [ ] Stakeholders and audience are identified142- [ ] Output format matches the audience's needs143- [ ] Key assumptions are documented144- [ ] Follow-up actions have clear owners