This skill should be used when you need to create, open, or edit a pull request (PR), or the user asks to "create a PR", "open a PR", "submit a PR", "raise a PR", "file a PR", "make a PR", "create a pull request", "open a pull request", "new PR", or any variation requesting GitHub pull request creation.
View on GitHubdhughes/claude-marketplace
pr-best-practices
plugins/pr-best-practices/skills/pr-creation/SKILL.md
January 24, 2026
Select agents to install to:
npx add-skill https://github.com/dhughes/claude-marketplace/blob/main/plugins/pr-best-practices/skills/pr-creation/SKILL.md -a claude-code --skill pr-creationInstallation paths:
.claude/skills/pr-creation/# Pull Request Creation Best Practices ## Purpose This skill enforces three critical best practices when creating GitHub pull requests: 1. **Include ticket numbers** - Associates PRs with tracking tickets (Jira, GitHub Issues) 2. **Use PR templates when available** - Ensures consistent, complete PR descriptions 3. **Create PRs as drafts by default** - Allows review before marking ready for review ## Ticket Detection and Integration Before creating the pull request, attempt to identify an associated ticket number from Jira or GitHub Issues. ### Detection Sources Check the following sources for ticket numbers (in order of preference): 1. **Conversation context** - Ticket mentioned in recent messages or conversation history 2. **Branch name** - Parse current branch name for ticket patterns: - `PROJ-123/description` (Jira-style prefix) - `feature/PROJ-123-description` (Jira after prefix) - `123-description` (GitHub issue number) - Other common patterns using intuition 3. **Recent commit messages** - Check for ticket references in commit messages 4. **Ask user** - If no ticket found in above sources, use AskUserQuestion to ask if there's an associated ticket ### Ticket Number Patterns Recognize these common patterns: - **Jira tickets**: `PROJ-123`, `ABC-456` (uppercase letters, hyphen, numbers) - **GitHub issues**: `#123`, `456` (numbers, optionally with # prefix) ### PR Title Integration When ticket number is identified, format the PR title as: ``` [TICKET-NUM] Descriptive PR title ``` Examples: - `[MSI-608] Add Zendesk integration` - `[#456] Fix authentication bug` - `[PLATFORM-123] Refactor API endpoints` ### PR Body Integration **If PR template exists with ticket field:** - Look for placeholders like `[TICKET]`, `[ISSUE]`, `Ticket:`, `Issue:`, `JIRA:`, etc. - Replace placeholder with ticket number (as link if URL can be determined) - Preserve template formatting **If template has no specific ticket field:** - Add ticket reference at the t