From escapement
Create context-aware pull requests with issue integration. Invoke when user says "create a PR", "open pull request", "make a PR", "submit for review", or after completing work on a feature branch.
How this skill is triggered — by the user, by Claude, or both
Slash command
/escapement:create-prThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Create well-structured pull requests that link to originating issues, summarize changes clearly, and facilitate effective code review. This skill analyzes the branch, detects related issues, and generates comprehensive PR descriptions.
Create well-structured pull requests that link to originating issues, summarize changes clearly, and facilitate effective code review. This skill analyzes the branch, detects related issues, and generates comprehensive PR descriptions.
This skill activates when the user says things like:
Execute these in parallel for efficiency:
Project Context:
CLAUDE.md for PR conventionsBranch Analysis:
git branch --show-current - Current branch namegit log main..HEAD --oneline - Commits on this branchgit diff main...HEAD --stat - Change summaryRemote Status:
Extract Issue Reference from Branch Name:
Common patterns:
42-feature-description → Issue #42feature/42-description → Issue #42fix/123-bug-name → Issue #123ABC-123-description → Linear issue ABC-123Retrieve Issue Details:
For GitHub Issues:
mcp__github__get_issue(owner, repo, issue_number)
For Linear Issues:
mcp__linear__get_issue(id)
Build Context Map:
Commit Analysis:
Change Summary:
Verify Completeness:
PR Title:
Format: {type}: {description} (#{issue_number})
Example: feat: Add commit-changes skill (#42)
PR Description Template:
## Summary
{Brief explanation aligned with original issue goals}
## Issue Resolution
Closes #{issue_number}
{How this implementation addresses the original requirements}
## Key Changes
- {Module-focused change descriptions}
- {New capabilities enabled}
- {Breaking changes if any}
## Implementation Notes
{Any deviations from issue description}
{Technical decisions made}
{Trade-offs considered}
## Testing
{How this was tested}
{What testing is appropriate for current project phase}
## Checklist
- [ ] Code follows project conventions
- [ ] Changes are atomic and reviewable
- [ ] Documentation updated (if needed)
- [ ] Tests added/updated (if applicable)
Use AskUserQuestion to confirm PR details:
AskUserQuestion:
question: "Ready to create this PR?"
header: "Create PR"
options:
- label: "Yes, create PR"
description: "Create the PR with this title and description"
- label: "Edit title"
description: "I want to modify the PR title"
- label: "Edit description"
description: "I want to modify the PR description"
- label: "Create as draft"
description: "Create as draft PR (not ready for review)"
- label: "Cancel"
description: "Don't create PR right now"
Display the proposed title and description before asking.
Ensure branch is pushed:
git push -u origin {branch-name}
Create PR using gh CLI:
gh pr create \
--title "{title}" \
--body "$(cat <<'EOF'
{PR description}
EOF
)" \
--base {target-branch}
Or use MCP GitHub tools:
mcp__github__create_pull_request(...)
IMPORTANT: Do NOT add Claude attribution (e.g., "Generated with Claude Code") to PR descriptions.
Apply labels (from issue + modules affected)
Link to issue (auto-close on merge via "Closes #X")
Display:
✓ Pull Request created!
🔗 PR #XX: {title}
{PR URL}
📋 Linked to Issue #{issue_number}
👀 Ready for review
Target: {target-branch}
Reviewers: {if any suggested}
Based on context, automatically determine:
Target Branch:
Labels:
Draft Status:
Reviewers:
ℹ️ No commits to create PR from.
Branch has no changes vs {target-branch}.
📤 Branch not on remote. Pushing now...
git push -u origin {branch}
⚠️ Could not find issue reference in branch name.
Branch: {branch-name}
Would you like to:
1. Enter issue number manually
2. Create PR without issue link
3. Cancel
ℹ️ PR already exists for this branch.
🔗 PR #{number}: {title}
Would you like to update it instead?
Follows:
do-work skill - After completing all taskscommit-changes skill - After final commitLinks to:
Version: 1.0.0 Last Updated: 2025-12-29 Maintained By: Escapement Converted From: commands/open-pr.md
npx claudepluginhub fusupo/escapement --plugin escapementCreates GitHub pull requests with formatted descriptions, labels, issue references, draft mode, reviewers, and base branch selection from pushed branches. Use for 'create PR' or 'submit for review'.
Creates GitHub pull requests from branch changes using git analysis and gh CLI, with conventional commit titles and standardized templated descriptions including summary, changes, testing, and checklists.
Creates pull requests with clear descriptions and test plans. Analyzes branch changes, detects ticket references, and runs code review before PR creation.