create-pull-request

Installation
SKILL.md

Create Pull Request

This skill ensures pull requests are created correctly using the gh CLI, adhering to branch naming, commit formatting, and PR templates.

Before Creating a PR (Pre-flight Checklist)

Before running gh pr create, please verify the state of the repository. Explain to the user why these checks are important for a clean Git history and smooth review process:

  1. Check uncommitted changes: Are there uncommitted changes? (Run git status). If yes, ask the user if they want them committed or stashed.
  2. Review your own diff: Do the changes match the PR intent? (Run git diff main...HEAD or similar). Avoid creating a PR without reviewing the diff so you can catch accidental inclusions like secrets or debug statements.
  3. Check the branch: Are you on the correct branch? Ensure you are opening a PR from a feature branch rather than directly from main or master to prevent accidental merges of incomplete work.
  4. Push the branch: Ensure the branch is pushed to the remote (git push -u origin <branch-name>) before creating the PR, otherwise the gh CLI will fail.

Expected Output

When a user asks to create a PR, clearly state the steps you are taking to verify the state of the repository and the branch. Once checks are complete, provide the exact gh pr create command that will be executed, and wait for the user to confirm before proceeding.

Branch & Title Conventions

  • Branch Naming: Use type/issue-number-slug or type/slug.
Related skills

More from hrdtbs/agent-skills

Installs
41
First Seen
Jan 27, 2026