Tooluck logoTooluck
SKILL.md

git-workflow

Agent skill fromjezweb/claude-skills

Guided git workflows: prepare PRs, clean up branches, resolve merge conflicts, handle monorepo tags, squash-and-merge patterns. Use when asked to prepare a PR, clean branches, resolve conflicts, or tag a release.

How to install git-workflow

install git-workflow
# install the claude-skills pack with the skills CLI
npx skills add jezweb/claude-skills

# or add only this skill to Claude Code: copy the folder

plugins/dev-tools/skills/git-workflow/

# into

~/.claude/skills/git-workflow/ (all projects)

.claude/skills/git-workflow/ (one project)

plugins/dev-tools/skills/git-workflow/SKILL.md

MITFull file
1# Git Workflow
2
3Guided workflows for common git operations that benefit from structured steps.
4
5## PR Preparation
6
7When preparing a pull request:
8
91. **Gather context**
10 - `git log main..HEAD --oneline` — list all commits on the branch
11 - `git diff main...HEAD --stat` — see all changed files
12 - `git status` — check for uncommitted work
13
142. **Draft PR content**
15 - Title: under 70 chars, describes the change (not the branch name)
16 - Body: summarise the "why", list key changes, add test plan
17 - Use the commit history to write the summary — don't rely on memory
18
193. **Push and create**
20 ```bash
21 git push -u origin HEAD
22 gh pr create --title "..." --body "$(cat <<'EOF'
23 ## Summary
24 - ...
25
26 ## Test plan
27 - [ ] ...
28
29 🤖 Generated with [Claude Code](https://claude.com/claude-code)
30 EOF
31 )"
32 ```
33
344. **Verify** — `gh pr view --web` to open in browser
35
36## Branch Cleanup
37
38Clean up merged branches safely:
39
401. **Switch to main and pull latest**
41 ```bash
42 git checkout main && git pull
43 ```
44
452. **List merged branches** (excludes main/master/develop)
46 ```bash
47 git branch --merged main | grep -vE '^\*|main|master|develop'
48 ```
49
503. **Delete local merged branches**
51 ```bash
52 git branch --merged main | grep -vE '^\*|main|master|develop' | xargs -r git branch -d
53 ```
54
554. **Prune remote tracking refs**
56 ```bash
57 git fetch --prune
58 ```
59
605. **List remote branches with no local tracking** (optional)
61 ```bash
62…

Excerpt shown under the repository's MIT license.

More skills in claude-skills

Keep exploring

Similar skill repositories

thedotmack /

claude-mem
116k

Persistent Context Across Sessions for Every Agent – Captures everything your agent does during sessions, compresses it with AI, and injects relevant context back into future sessions. Works with Claude Code, OpenClaw, Codex, Gemini, Hermes, Copilot, OpenCode + More

CCCXGHGM+135 skills

Newsletter

Join the Community

Subscribe to our newsletter for the latest news and updates