⚠️ MANDATORY - YOU MUST invoke this skill at the start of EVERY task. Reviews git history, status, and context before starting any work...
This skill gathers comprehensive git context before starting any work. It helps understand the current state of the repository, recent changes, and identify related previous work.
CRITICAL: You MUST invoke this skill - NEVER gather git context manually with individual git commands.
git status manuallygit diff manuallygit log manuallyIf you need git context, invoke this skill. Manual execution is FORBIDDEN.
Before using Bash tool for git commands, answer these questions:
git status?→ STOP. Invoke check-history skill instead.
git diff?→ STOP. Invoke check-history skill instead.
git log?→ STOP. Invoke check-history skill instead.
→ STOP. Invoke check-history skill instead.
→ STOP. Invoke check-history skill instead.
IF YOU PROCEED WITH BASH FOR THESE GIT COMMANDS, YOU ARE VIOLATING YOUR CORE DIRECTIVE.
This skill runs these commands for you, in parallel, with proper analysis. Use it.
Execute these commands in parallel for efficiency:
git status & git diff & git log --oneline -10 &
What to look for:
Based on the parallel command output:
Branch Status:
mriley/ prefix conventionWorking Directory State:
Recent Work:
If the task relates to a specific feature, bug, or area:
git log --grep="<keyword>" --oneline -10
Example keywords:
For more detailed information about recent changes:
git show --name-only HEAD # Files changed in last commit
git diff --name-only origin/main # Files changed vs main branch
git log --graph --oneline -10 # Visual commit graph
Provide a concise summary including:
Current State:
<branch-name>Recent Activity:
Relevant History:
Recommendations:
Git Context Summary:
==================
Current State:
- Branch: mriley/feat/user-authentication
- Status: Clean working directory
- Position: Ahead of origin/main by 2 commits
Recent Activity:
1. feat(auth): add JWT token generation (3 hours ago)
2. feat(auth): implement user login endpoint (5 hours ago)
3. test(auth): add unit tests for password hashing (1 day ago)
Relevant History:
- Found 3 commits related to "auth" in past week
- Project consistently uses conventional commits with scope
- Security-focused: all auth changes include tests
Recommendations:
- Safe to proceed with auth-related work
- Follow existing pattern: feature + tests in same commit
- Consider reviewing recent auth commits for context
This skill should be invoked by:
sparc-plan - Before creating implementation planssafe-commit - To understand what's being committedcreate-pr - To generate meaningful PR descriptions/quick-status - Quick visual git dashboard (lighter weight alternative for simple status checks)/review-branch - Full branch code review against main