Create Pull Request
Create a pull request with automatic quality checks and proper commit message.
Usage
cursor
/pr Add newsletter subscription feature
The description after /pr becomes the commit subject.
Steps
- •
Verify branch
- •Confirm current branch is not
mainormaster - •Run
git statusto see all changes
- •Confirm current branch is not
- •
Run quality checks
- •Execute
pnpm preflight(all checks) - •If any check fails, stop and report errors
- •Do not proceed with failing checks
- •Execute
- •
Review changes
- •Run
git diffto review all modifications - •Run
git log origin/main..HEADto see commits - •Verify changes align with the description
- •Run
- •
Create commit
- •Stage relevant files with
git add - •Generate conventional commit message:
- •Format:
<type>(<scope>): <description> - •Types:
feat,fix,docs,style,refactor,perf,test,chore - •Scopes:
blog,i18n,components,seo,security,api,ci,docs
- •Format:
- •Include trailer:
Co-Authored-By: Claude <noreply@anthropic.com>
- •Stage relevant files with
- •
Push and create PR
- •Push to remote:
git push -u origin HEAD - •Create PR using
gh pr createwith:- •Title matching commit message
- •Body with summary and test plan
- •Link to related issues if any
- •Push to remote:
- •
Return PR URL
- •Display the GitHub PR URL for review
Requirements
- •
ghCLI must be installed and authenticated - •Current branch must not be
mainormaster - •All quality checks must pass
Example Commit Messages
- •
feat(blog): add rss feed generation - •
fix(i18n): correct czech translation for homepage - •
docs: update deployment instructions - •
refactor(components): simplify button variant logic