save
Save current session state to a dated file in ~/.claude/session-data/ so work can be resumed in a future session with full context.
Capture the full session state and write it to a dated file.
Steps:
-
Gather context — review git diff, files modified, decisions made, errors encountered
-
Create folder:
mkdir -p ~/.claude/session-data -
Write file:
~/.claude/session-data/YYYY-MM-DD-{short-id}-session.tmp- short-id: lowercase letters/digits/hyphens, 8+ chars (e.g.,
abc123de) - Legacy format
YYYY-MM-DD-session.tmpis still valid
- short-id: lowercase letters/digits/hyphens, 8+ chars (e.g.,
-
File must include:
- Session metadata: date, project, branch, working directory
- Completed work: what was built/fixed, commits made
- Current state: branch, uncommitted changes, test/build status
- Pending tasks: what's next, in priority order
- Open decisions: unresolved questions or design choices
- Known issues: errors encountered and resolution status
- Environment: relevant versions, env vars, dependencies
- Key files: most important files touched, with brief purpose
- Next step: the exact first action for the next session
-
Confirm: report the file path and key summary to the user
Resume next session with /dog:resume.