Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Create pull requests using GitHub CLI with proper templates and formatting
| Test case | Without → With | Effect | Δ tokens | Δ turns |
|---|---|---|---|---|
| case-10 | ✗→✓ | ▲ Improved | 117% | 0% |
| case-15 | ✗→✓ | ▲ Improved | 13% | 0% |
| case-04 | ✓→✓ | = Same ✓ | 18% | 0% |
| case-05 | ✓→✓ | = Same ✓ | -5% | 0% |
| case-06 | ✓→✓ | = Same ✓ | 202% | 0% |
This guide explains how to create pull requests using GitHub CLI in our project.
Important: All PR titles and descriptions should be written in English.
Check if gh is installed, if not follow this instruction to install it:
bash # macOS brew install gh
# Windows winget install --id GitHub.cli
# Linux # Follow instructions at https://github.com/cli/cli/blob/trunk/docs/install_linux.md
bash gh auth login
Before creating a PR, check for uncommitted changes:
git status to check for uncommitted changes (staged, unstaged, or untracked files)commit skill first: Skill: commit
gh pr create --draft command to create a new pull request:bash # Basic command structure gh pr create --draft --title "✨(scope): Your descriptive title" --body "Your PR description" --base main
For more complex PR descriptions with proper formatting, use the --body-file option with the exact PR template structure:
bash # Create PR with proper template structure gh pr create --draft --title "✨(scope): Your descriptive title" --body-file .github/pull_request_template.md --base main
:sparkles:)✨(supabase): Add staging remote configuration🐛(auth): Fix login redirect issue📝(readme): Update installation instructionspr_agent:summary and pr_agent:walkthrough)--draft flag in the commandgh pr readyAlways include all template sections, even if some are marked as "N/A" or "None"
Here are some additional useful GitHub CLI commands for managing PRs:
bash# List your open pull requests gh pr list --author "@me" # Check PR status gh pr status # View a specific PR gh pr view <PR-NUMBER> # Check out a PR branch locally gh pr checkout <PR-NUMBER> # Convert a draft PR to ready for review gh pr ready <PR-NUMBER> # Add reviewers to a PR gh pr edit <PR-NUMBER> --add-reviewer username1,username2 # Merge a PR gh pr merge <PR-NUMBER> --squash
To simplify PR creation with consistent descriptions, you can create a template file:
pr-template.md with your PR templatebashgh pr create --draft --title "feat(scope): Your title" --body-file pr-template.md --base main
Other measured skills in the registry, with their headline benchmark lift.