create-pr
Installation
SKILL.md
When creating a PR:
- Use
gh pr create - Use the target repo's dedicated PR template when one exists.
- Otherwise, use
pull_request_template.mdfrom this package as the fallback template. - Follow merge-queue conventions.
Merge-queue mapping
- PR title = commit title (Conventional Commits format).
- PR description = commit body (reusable as commit message content).
- PR title max: 72 characters.
- PR description line max: 72 characters, except long URLs, code blocks, or stack traces.
Description rules
- The first line must be plain context text describing the change.
- After the context line, follow the selected template.
- If the target repo has a dedicated PR template, follow that template after the context line.
- Otherwise, append the sections from
pull_request_template.mdafter the context line. - Do not add extra headings beyond those required by the selected template.
- Fill
CONFIG-CHANGE:andBREAKING-CHANGE:sections when applicable. - Remove
CONFIG-CHANGE:and/orBREAKING-CHANGE:sections entirely if there is no config change or breaking change respectively. - Keep the description concise and commit-friendly.
Steps
- Run the
verifyskill if it has not been run since the last code change. All matching checks must pass before proceeding. - Review all commits on the branch
(
git logandgit diffagainst the base branch). - Draft a PR title (Conventional Commits format, 72 chars max).
- Draft a PR description that starts with a plain context line.
- If the target repo has a dedicated PR template, follow that template
after the context line; otherwise append
pull_request_template.mdafter the context line. - Ask for confirmation from the user with all this information.
- Check if the branch needs to be pushed to remote.
- Create the PR.
- Return the PR URL.
Related skills