Push branch and create PR with generated details
Pushes current branch and creates a Pull Request with AI-generated title and description.
/plugin marketplace add adeonir/claude-code-extras/plugin install git-helpers@claude-code-extras[base-branch]Push current branch and create Pull Request via gh cli.
base-branch: Use specified branch as base for comparisonCheck gh cli availability:
which gh
If not available, stop and inform user to install gh cli or use /git-helpers:details instead.
Detect base branch (if not specified):
git branch -a | grep -E "(main|master|develop)$" | head -1
Gather context (run in parallel):
git branch --show-current
git log {base}..HEAD --oneline
git diff {base}...HEAD --stat
git diff {base}...HEAD
Analyze changes:
Create PR:
gh pr create --title "type: description" --body "..."
| Type | Use when |
|---|---|
feat | Adding new functionality |
fix | Fixing a bug |
refactor | Restructuring code without changing behavior |
chore | Maintenance tasks, dependencies, configs |
docs | Documentation changes |
test | Adding or updating tests |
Title: type: concise description or type(scope): concise description
Body:
Brief summary of what this PR does (2-3 sentences max).
## Changes
- Key change 1
- Key change 2
- Key change 3
feat: and feat(scope): are validGenerate PR details for current branch with $ARGUMENTS and create PR using gh pr create.
Output the PR URL when done.