Automated summary
Creates a well-structured pull request with a product-focused summary, change highlights, and test steps, auto-detecting the base branch and linking Linear issues from the branch name.
Strengths
- Fully automated PR creation with branch detection and push
- Native Linear integration for issue linking and branch renaming
- Product-oriented PR template with summary, changes, and test steps
- Configurable preferences for base branch, template, and auto-push
Limitations
- Requires GitHub CLI (gh) and git to be installed and authenticated
- Linear integration relies on branch naming convention
- May fail if permissions or tokens are missing for gh or Linear
Use this skill when you have committed changes on a branch and want to open a PR with a detailed, product-centric description and automatic issue tracking.
Do not use this skill if your changes are incomplete or not ready for review, if you need a non-standard PR workflow, or if you use a different issue tracker.
Security analysis
CautionThe skill uses Bash to run git and gh commands for legitimate PR operations. It does not include destructive or exfiltrating actions, but the use of command execution in the environment warrants caution.
No concerns found
How this analysis is madeExamples
/create-pr/create-pr AIS-810/create-pr --base develop --draftname: create-pr description: >- Creates a well-structured pull request with product-focused summary, change highlights, and test steps. Auto-detects base branch, links Linear issues from branch name, and pushes if needed. Use when ready to open a PR or when asking to create a pull request. argument-hint: [issue-id] [--base branch] [--draft] disable-model-invocation: true allowed-tools:
- AskUserQuestion
- Bash
- Read
- Glob
- Grep
- mcp__claude_ai_Linear__get_issue
- mcp__claude_ai_Linear__update_issue
Create PR
Create a well-structured, product-focused pull request.
Preferences
Read ~/.claude/skills/create-pr/preferences.md using the Read tool. If not found, no preferences are set.
Context
On startup, use Bash to detect: current branch (git branch --show-current), upstream branch, commits ahead of upstream, and repo name (gh repo view --json nameWithOwner -q .nameWithOwner). Skip any that fail.
Command routing
Check $ARGUMENTS:
help→ display help then stopconfig→ interactive setup then stopreset→ delete~/.claude/skills/create-pr/preferences.md, confirm, stop- anything else (including empty) → create PR
Flags
Parse from $ARGUMENTS:
--base <branch>— override base branch--draft— create as draft PR--no-linear— skip Linear integration- Remaining text — treated as Linear issue ID if it matches pattern (e.g.,
AIS-810)
Help
PR — Create a well-structured pull request
Usage:
/create-pr Create PR from current branch
/create-pr <issue-id> Create PR and link Linear issue
/create-pr --base develop Override base branch
/create-pr --draft Create as draft
/create-pr --no-linear Skip Linear linking
/create-pr config Set PR preferences
/create-pr reset Clear preferences
/create-pr help This help
Examples:
/pr
/create-pr AIS-810
/create-pr --base develop --draft
/create-pr AIS-810 --base main
What it does:
1. Detects base branch (or uses preference/flag)
2. Reads commits, diff, and Linear issue
3. Builds product-focused PR description
4. Pushes branch if needed
5. Creates PR and links to Linear
Current preferences:
(shown above under Preferences)
Config
Use AskUserQuestion:
Q1 — "Default base branch?" (auto-detect (default), main, develop, custom)
- Auto-detect: checks tracking branch, falls back to repo default branch
Q2 — "Link Linear issues?" (Yes — from branch name (default), No)
Q3 — "PR template?" (standard (default), minimal, detailed)
Q4 — "Auto-push before creating?" (Yes (default), No — just create locally)
Q5 — "Default PR type?" (Ready for review (default), Draft)
Save to ~/.claude/skills/create-pr/preferences.md.
First-time detection
If no preferences file exists, show:
"First time using /pr? Run /create-prconfig to set defaults (base branch, template, Linear linking), or continue — I'll auto-detect."
Then proceed.
Steps
1. Gather context
From git:
- Current branch (pre-injected)
- Commits on this branch:
git log <base>..HEAD --oneline - Diff stat:
git diff <base>...HEAD --stat - Full diff summary:
git diff <base>...HEAD(for understanding changes)
Base branch detection (in order):
--baseflag if provided- Saved preference if set
- Tracking branch upstream
- Repo default branch:
gh repo view --json defaultBranchRef -q .defaultBranchRef.name
Linear issue (unless --no-linear):
- Extract issue ID from branch name (pattern:
user/ais-NNN-*orais-NNN-*) - If found, fetch via
get_issuefor title, description, project
Remote check:
- Is branch pushed? If not, needs pushing.
2. Branch alignment
If a Linear issue was found, check if branch name matches issue.gitBranchName.
If mismatch, rename the branch to match (team convention):
git branch -m {old} {new}
git push origin --delete {old} # if old was pushed
git push -u origin {new}
3. Push if needed
If branch isn't pushed (or was renamed):
git push -u origin {branch}
Skip if --no-push or preference says no.
4. Build PR content
Title format: Under 70 chars, conventional prefix.
feat: Descriptionfor new featuresfix: Descriptionfor bug fixesrefactor: Descriptionfor refactoringchore: Descriptionfor maintenance
Body template (standard):
## Summary
{1-2 sentences: what this does and why. Product value first.}
**Linear:** [{issue-id}]({url}) (if available)
## What's New
- **{Feature/Change}** — {one sentence, user perspective}
- **{Feature/Change}** — {one sentence}
## How to Test
1. {Step}
2. {Step}
3. {Step}
Body template (minimal):
{1-2 sentences: what and why}
Linear: [{issue-id}]({url})
Body template (detailed):
## Summary
{1-2 sentences}
**Linear:** [{issue-id}]({url})
## What's New
- **{Feature}** — {description}
## Architecture
- {How it's structured}
- {What was reused}
- {Data flow}
## How to Test
1. {Step}
2. {Step}
5. Create the PR
gh pr create --base {base} --title "{title}" --body "$(cat <<'EOF'
{body}
EOF
)"
Add --draft if flag set or preference is draft.
6. Link to Linear
If Linear issue found, attach PR via update_issue with link:
url: https://github.com/{org}/{repo}/pull/{number}
title: PR #{number} — {title}
7. Report
PR created: {url}
Base: {base}
Head: {branch}
Title: {title}
Linear: {issue-id} (linked ✓) or "none"
Type: Ready / Draft
Commits: {count}
Files: {count}
8. Learn
- If user changes base branch, save preference
- If user edits the generated title pattern, save style preference
- If user consistently uses draft, save as default
From the file to a first result
The download contains exactly the content displayed on this page. This copy may differ from the latest version in the source repository.
View the source and supporting filesThis download contains SKILL.md only. Any scripts, references, templates and dependencies are not included. Get the required files from the source, preserving their directory structure, before continuing.
1. Download the file
Download SKILL.mdFrom the root of a test project, save the file as .skill-downloads/create-structured-pull-request-mm78nnq6/SKILL.md, or use the command below. This folder is for inspecting the skill before installation.
Command for macOS/Linux or WSL: requires a POSIX shell and curl. On Windows without WSL, use the download button and create the folder manually.
mkdir -p '.skill-downloads/create-structured-pull-request-mm78nnq6' && curl --fail --show-error --location 'https://skills-guides.com/api/skills/create-structured-pull-request-mm78nnq6/download' --output '.skill-downloads/create-structured-pull-request-mm78nnq6/SKILL.md.part' && mv '.skill-downloads/create-structured-pull-request-mm78nnq6/SKILL.md.part' '.skill-downloads/create-structured-pull-request-mm78nnq6/SKILL.md'2. Check prerequisites
Read SKILL.md before using it. If it references scripts or external services, inspect them and prepare the required access in your test environment.
No recognized prerequisites section in this file. This does not mean it is self-contained: libraries, tools and access requirements may be mentioned elsewhere in the content or source repository.
The platforms on this page are catalog indications. The paths below follow tool documentation; they do not prove this skill has been run in those tools. No minimum tool version is confirmed for this listing.
3. Load the skill
This file does not provide a usable name/description header for this native procedure. It remains available to download and inspect; use the manual method below.
Manual method or another tool: attach SKILL.md to a conversation, or open it in an agent that can read files. Include any required supporting resources. No universal folder is recognized by every tool.
4. Try a first task
Use a short, synthetic input: an API endpoint, a small document or an interface brief. In a new conversation, attach the file or give the agent its path, then adapt this request:
Read .skill-downloads/create-structured-pull-request-mm78nnq6/SKILL.md and apply its instructions to this example: [describe a test input]. Identify any missing files, dependencies or access. Produce the result requested by the skill without inventing data or running unreviewed scripts.Expected result: output matching the skill instructions, or a precise list of missing prerequisites. A read confirmation alone does not validate a first use. If an external resource is unavailable, that path remains untested.
React Hook Form Best Practices
Development
Master React Hook Form: avoid anti-patterns, manage subscriptions, and handle reset, dirty state, and controlled inputs correctly.
Emotion to Mantine Migration
Development
Migrate Emotion styled-components to Mantine components with style props and CSS modules. Use when converting .styled.tsx files or removing @emotion imports.
Scope Creep Detector
Development
Analyzes git diffs against a stated intent to detect scope creep, unrelated files, broad PRs, and oversized changes, then suggests keep, split, or justify actions.