create-pr

Pushes a feature branch and opens a GitHub pull request into main with a Conventional Commits title.

Updated Aug 1, 2026
One-click install
npx skills add https://github.com/dxiiren/project-skeleton --skill create-pr-dxiiren
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: create-pr
Source: https://github.com/dxiiren/project-skeleton/tree/main/.claude/skills/create-pr
Command: npx skills add https://github.com/dxiiren/project-skeleton --skill create-pr-dxiiren

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Opening a pull request involves repetitive manual steps: verifying the branch state, pushing to origin, writing a Conventional Commits title, drafting a structured PR body, and invoking the GitHub CLI. This Skill automates that entire flow while enforcing preconditions that prevent common mistakes like PRs from main, dirty trees, or duplicate PRs. ## Core Features & Use Cases - Precondition validation: Checks that you are on a feature branch, the working tree is clean, commits exist ahead of main, gh is authenticated, and no open PR already exists for the branch. - Conventional Commits title and clean body: Reuses a single commit's subject or synthesizes a title from multiple commits, then builds a Summary / Changes / Testing body with no attribution footer. - GitHub CLI or MCP execution: Pushes the branch with git push -u and opens the PR via gh pr create or the GitHub MCP create_pull_request, then reports the PR URL, number, and commit count. - Use Case: After finishing a feature branch and running /commit, say "create pr" and the Skill pushes the branch, drafts the title and body from the actual diff, and opens the PR into main. ## Quick Start Ask the assistant to create a PR for the current branch, for example by saying "create pr for this branch" after committing your changes.

Frequently Asked Questions about create-pr

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create a GitHub pull request from the command line?▼

Push your branch with git push -u origin, then run gh pr create with a base, head, title, and body file. This Skill automates both steps, generating a Conventional Commits title and a structured body from your commits.

How do I write a good pull request title and body?▼

Use a Conventional Commits title like feat(scope): summary, reusing a single commit's subject when possible. The body should contain Summary, Changes, and Testing sections filled from the actual diff, with no attribution footers.

Can I create a PR if my working tree has uncommitted changes?▼

No. The Skill stops if git status shows a dirty tree and instructs you to commit first. Opening a PR over uncommitted changes risks missing work, so the tree must be clean before proceeding.

What happens if a pull request already exists for my branch?▼

The Skill runs gh pr list --head to detect an existing open PR. If one exists, it shows the PR and asks whether to push new commits to update it or stop, never silently creating a duplicate.

Does gh pr create work without the GitHub CLI authenticated?▼

No, gh auth status must succeed first. If authentication fails, run gh auth login, or the Skill can fall back to the GitHub MCP create_pull_request if that integration is configured.