Git Checkpoint Management
Create, list, and restore Git checkpoints (stashes) for safe code exploration and recovery of previous states without committing.
Sby Skills Guide Bot
DevOpsIntermediate0 views0 installs3/1/2026Claude CodeCursorWindsurf
gitversion-controlcheckpointstashrecovery
name: checkpoint description: Git checkpoint management - create, list, restore checkpoints. Invoke when starting risky changes or needing safe recovery points. allowed-tools: Bash, Read, Write, Glob
Git checkpoint system
Manage git checkpoints (stashes) for safe code exploration and recovery.
When to invoke
- Before making risky changes or refactoring
- When you want a quick save point without committing
- To restore previous state after experiments fail
- To maintain multiple work-in-progress states
Usage
/checkpoint create [name] # Create a named checkpoint
/checkpoint list # List checkpoints
/checkpoint restore [name] # Restore a specific checkpoint
/checkpoint pop # Restore the most recent checkpoint
/checkpoint clear # Remove checkpoints
Instructions
Create checkpoint
- Check if in a git repository
- Check for uncommitted changes
- Create a git stash with the name:
claude-checkpoint_YYYYMMDD_HHMMSS: [name] - Confirm the checkpoint creation
List checkpoints
- Run
git stash list - Filter stashes that start with
claude-checkpoint - Display in a formatted table:
- Index (stash@{N})
- Timestamp
- Description
- Number of files changed
Restore checkpoint
- Find the stash matching the given name or index
- Apply the stash with
git stash apply stash@{N} - Do NOT drop the stash (keep it for safety)
- Report restoration details
Pop checkpoint
- Find the recent
claude-checkpointstash - Apply it with
git stash pop stash@{N} - Report restoration details
Clear checkpoints
- List
claude-checkpointstashes - Ask for confirmation before proceeding
- Drop each matching stash
- Report removal count
Examples
# Create checkpoint before risky changes
/checkpoint create "before refactoring auth module"
# List checkpoints
/checkpoint list
# Restore if something went wrong
/checkpoint restore "before refactoring auth module"
# Quick restore of the recent one
/checkpoint pop
# Clean up old checkpoints
/checkpoint clear
Notes
- Checkpoints rely on git stash under the hood
- Include untracked files in checkpoints
- Checkpoints persist across sessions
- Apply descriptive names for identification
Related skills
Docker Compose Architect
100
Designs optimized Docker Compose configurations.
Claude CodeCopilotadvanced
4301561261Admin
Incident Postmortem Writer
100
Writes structured and blameless incident postmortem reports.
claudeCursorWindsurfintermediate
14143333Admin
Runbook Creator
100
Creates clear operational runbooks for common DevOps procedures.
claudeCursorWindsurfintermediate
10832259Admin