aboutsummaryrefslogtreecommitdiffstats
path: root/modules/development/pi-coding-agent/skills/git/SKILL.md
blob: df60f8f7456de73bb5da411739acb9be0818da2c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
---
name: git
description: "Inspect status/diff/history, preserve user work, create focused commits when requested, help with merges/rebases/conflicts."
---

# Git Skill

Inspect status/diff/history, preserve user work, create focused commits when requested, help with merges/rebases/conflicts.

## Subagents
When you need to delegate sub‑tasks, use the `pi-subagents` skill.

**Example:** When preparing a complex merge, spawn a **scout** to analyze the commit history of the `feature` branch, another **scout** to inspect the conflicting files in `core`, and a **reviewer** to verify the merged result passes all tests before pushing.

*You may adapt the delegation pattern to fit the exact requirements of the codebase.*

## Operations

### Inspect
- `git status` - working tree state
- `git diff` - unstaged changes
- `git diff --cached` - staged changes
- `git log --oneline -20` - recent history

### Preserve
- Never discard user changes
- Stash before risky operations
- Backup before rewrites

### Commit
- One logical change per commit
- Clear, imperative messages
- Reference issues when applicable
- Use strict commit message formats

### Merge
- Prefer merge with commits
- Resolve conflicts incrementally