/git-flow:setupfrom git-flow
Use this skill when the user asks an agent to audit, configure, or migrate a Git/GitHub repository to a safe GitHub Flow-inspired model with main as production and develop as the dedicated development/integration branch. Applies to branch model audits, migration plans, default branch checks, gh-assisted repository configuration, and solo-developer workflow guidance.
Ships in git-flow. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them; scripts run unread.
Use this workflow when auditing or migrating a repository to a simple solo-developer branch model:
main is production-ready, stable code only.develop is the primary development and integration branch.develop.develop to main.Optimize for safety, clarity, reversibility, and repository integrity over speed.
git reset --hard, git clean, git restore, force push, forced
branch deletion, or other destructive commands.git status --short before branch or repository operations.scripts/validate_migration.py validates target model classification,
branch names, allowed branch relationships, and migration readiness inputs.references/migration_checklist.md contains the audit report template,
migration plan template, approval gate, readiness gate, and final summary
template. Read it before audit output and before migration execution.Inspect and report current state without changing anything.
Use explicit, read-only commands:
git status --short
git branch --show-current
git branch --list
git branch --remotes
git remote -v
gh repo view --json nameWithOwner,defaultBranchRef
Inspect branch relationships and recent usage with explicit branch names once branches are known:
git log --oneline --decorate --graph --max-count=30 --all
git rev-list --left-right --count main...develop
git branch --merged main
git branch --no-merged main
git branch --merged develop
git branch --no-merged develop
If main or develop does not exist, do not run comparisons that assume they
do. Report the missing branch instead.
Audit must cover:
git status --shortClassify the current workflow conservatively as one of:
Compare current state against the desired model:
main exists and appears production-focused.develop exists and appears to be the integration branch.develop to main.Classify repository readiness:
Already aligned
Partially aligned
Requires migration
Unsafe to migrate
Validate the classification string if using the helper:
python3 scripts/validate.py classification "Partially aligned"
Clearly explain:
Do not assume intent. Infer conservatively.
If migration is needed, generate a step-by-step plan before changing anything. Each step must be explicit, minimal, and reversible where possible.
The plan must address:
developUse the plan template in references/checklist.md.
Before changing anything, present:
Ask for explicit approval. Do not proceed without clear user confirmation.
Proceed only if:
Use minimal, explicit commands. Typical approved operations may include:
git branch develop main
gh repo edit --default-branch develop
Only use commands that match the approved plan. Do not create develop from
main, or from any other branch, until the audit has identified the correct
base and the user has approved that base.
For GitHub default branch updates, prefer gh repo edit --default-branch develop only when the plan explicitly calls for it and the repository state is
ready.
If migration is unsafe, stop immediately and explain why. Provide concrete readiness steps, such as:
Do not perform readiness steps automatically unless explicitly approved.
After approved migration steps, verify:
git status --short
git branch --list main develop
gh repo view --json defaultBranchRef
Then verify:
main exists and is stabledevelop exists and is the correct integration branchUse the final summary template in references/checklist.md.
Include:
Recommended workflow:
develop.develop.develop to main.What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub liljamesjohn-archive/codecave --plugin git-flow5 skills in this plugin
/branchUse this skill when the user asks an agent to create, switch, merge, validate, or manage Git branches using a safe Git Flow-inspired model with main as production and develop as the integration branch. Applies to feature, fix, hotfix, release, chore, refactor, test, and docs branch workflows./commitUse this skill when the user asks an agent to create, split, validate, or repair Git commits with strict atomic boundaries and Conventional Commit messages. It is for safe commit crafting, staged-diff review, gh-assisted issue or PR context, and disciplined commit history work./pull-requestUse this skill when the user asks an agent to create, update, inspect, validate, or manage pull requests with review-friendly standards, safe Git/GitHub CLI workflows, clear PR descriptions, Conventional Commit-style titles, branch target validation, and repository hygiene.