| name | pr-workflow |
| description | Complete pull request workflow from feature branch creation to PR submission. Use when starting a new feature, fixing a bug, or preparing code for review. |
Pull Request Workflow
Purpose
A complete workflow for creating, developing, and submitting pull requests following project conventions.
Workflow Phases
Phase 1: Branch Setup
-
Ensure clean state:
git status
-
Create feature branch:
git checkout -b <type>/<description>
Branch naming convention:
feat/<description> - New features
fix/<description> - Bug fixes
docs/<description> - Documentation
refactor/<description> - Code refactoring
test/<description> - Test additions/fixes
Phase 2: Development
- Make changes following project conventions
- Run quality checks:
make lint
make test
- Fix any issues using
lint-and-fix and test-and-fix skills
Phase 3: Pre-PR Verification
Before creating PR, run full verification:
-
Invoke verifier agent:
Use the verifier subagent to run complete build → lint → test cycle
-
Review changes:
git diff main...HEAD
-
Invoke code-reviewer agent (optional but recommended):
Use the code-reviewer agent for quality assessment
Phase 4: Commit Changes
-
Stage files:
git add <specific-files>
Avoid git add -A - be explicit about what's committed.
-
Create commit:
git commit -m "type(scope): description"
Conventional commit types:
feat: New feature
fix: Bug fix
docs: Documentation
style: Formatting (no code change)
refactor: Code restructuring
test: Test changes
chore: Maintenance tasks
Phase 5: Create Pull Request
-
Push branch:
git push -u origin <branch-name>
-
Create PR using gh CLI:
gh pr create --title "type(scope): description" --body "$(cat <<'EOF'
## Summary
- Brief description of changes
- Key implementation details
## Changes
- List of specific changes made
## Testing
- [ ] Unit tests pass
- [ ] Lint checks pass
- [ ] Manual testing done (if applicable)
## Related Issues
Closes #<issue-number> (if applicable)
EOF
)"
PR Description Template
## Summary
[1-3 sentences describing what this PR does and why]
## Changes
- [Specific change 1]
- [Specific change 2]
- [Specific change 3]
## Testing
- [ ] All tests pass (`make test`)
- [ ] Linting passes (`make lint`)
- [ ] Build succeeds (`make build`)
- [ ] Manual testing completed (if applicable)
## Checklist
- [ ] Code follows project style guidelines
- [ ] Self-review completed
- [ ] Documentation updated (if needed)
- [ ] No sensitive data committed
Quick Commands Reference
| Task | Command |
|---|
| Check branch status | git status |
| View changes | git diff |
| Stage all changes | git add -A |
| Stage specific file | git add <file> |
| Commit changes | git commit -m "message" |
| Push branch | git push -u origin <branch> |
| Create PR | gh pr create |
| View PR status | gh pr status |
| List open PRs | gh pr list |
Troubleshooting
PR Checks Failing
- Run
make lint && make test locally
- Fix any issues
- Push fixes:
git add . && git commit -m "fix: address PR feedback" && git push
Merge Conflicts
- Fetch latest:
git fetch origin main
- Rebase:
git rebase origin/main
- Resolve conflicts
- Continue:
git rebase --continue
- Force push:
git push --force-with-lease