create-pr
Create a GitHub pull request from the current branch after validating branch readiness, reading the real diff, drafting a precise title and body, pushing the branch, and verifying the created PR. User-only workflow: use when the user explicitly asks to open or create a PR.
What this skill does
<EXTREMELY-IMPORTANT> This skill mutates remote collaboration state and must stay explicit. Non-negotiable rules: 1. Read the full diff against the real base branch before drafting the PR. 2. Block on protected-branch usage, empty branch state, or conflict markers. 3. If uncommitted changes exist, invoke `commit` first instead of creating a misleading PR. 4. Push the branch before creating the PR. 5. Keep PR creation user-driven. If title, scope, base, or reviewer intent is ambiguous, ask first. </EXTREMELY-IMPORTANT> # Create PR ## Inputs - `$request`: Optional PR guidance such as draft intent, reviewer hints, base branch, labels, or title direction ## Goal Create a PR that matches the actual branch changes and leaves the user with: - a correct base branch - an accurate title - a useful body - a pushed branch - a verified PR URL and state ## Step 0: Confirm this is an explicit PR request This skill is user-only. Use it only when the user explicitly asks to create or open a PR. If the request is really: - code review only, route to a review skill - commit creation only, route to `commit` - planning only, route to the planner If reviewer assignment, labels, milestone, or base branch are ambiguous and matter to the request, use `AskUserQuestion`. **Success criteria**: PR creation is explicitly requested and the intended PR shape is clear enough to proceed. ## Step 1: Gather real branch context Inspect the current branch before drafting anything: - current branch name - branch tracking state - uncommitted changes - base branch candidates - commits ahead of base - full diff against base Rules: - read the actual diff, not just commit messages - determine the real base branch before classifying the PR - use `Read` on changed files when the diff summary is not enough to understand the change Load `references/pr-conventions.md` for base-branch selection and PR classification heuristics when needed. **Success criteria**: You know the branch, base, diff shape, and whether the branch is actually PR-ready. ## Step 2: Validate branch readiness Blockers: - on `main`, `master`, or `develop` - no commits relative to base - conflict markers in changed files If uncommitted changes exist: - invoke the `commit` skill - then re-run branch context gathering before continuing Warnings: - type or lint failures are warnings unless the user wants to stop and fix them first - breaking changes are not blockers, but they must be documented **Success criteria**: The branch is in a state where a PR can be created honestly. ## Step 3: Classify the PR from the actual diff Determine: - type - scope - size - risk - whether breaking changes exist Use: - branch name as a hint, not truth - changed paths and modules - commit messages only as supporting context - the full diff as the source of truth Document breaking changes if any of these exist: - removed or renamed public exports - route or API contract changes - schema or migration changes - env var changes - major dependency changes Load `references/pr-conventions.md` for: - classification heuristics - title rules - option flag mapping - blocking versus warning behavior **Success criteria**: The PR is classified from the real code changes, not just branch naming. ## Step 4: Run the narrowest relevant quality checks Run checks that fit the changed surface and project tooling. Typical checks: - typecheck - lint - conflict-marker scan Rules: - conflict markers always block - other failures should be surfaced honestly to the user - do not fabricate passing status in the PR body - if the user asks to proceed with known non-blocking issues, say so explicitly in the final report **Success criteria**: The PR reflects the actual readiness state of the branch. ## Step 5: Draft the PR title and body Create: - a Conventional Commit-style PR title - a body that explains what changed and how to review it The body should cover: - summary - grouped change areas - breaking changes when present - specific test plan - optional notes for deployment, config, or dependency changes Use: - `references/pr-conventions.md` for title and readiness rules - `references/pr-body-examples.md` only when you need example body shape If the user explicitly provided title guidance, use it if it still matches the actual diff. **Success criteria**: The title and body describe the full branch accurately and are reviewable. ## Step 6: Push the branch and create the PR Before creation: - ensure the branch is pushed - ensure upstream is set if needed Then create the PR with `gh pr create`. Support request-driven options such as: - draft - reviewer - assignee - label - milestone Rules: - do not create the PR before the branch exists on remote - prefer `gh` over manual API calls - if `gh` is unavailable, stop and provide the user with the prepared title, body, and compare URL **Success criteria**: The PR exists remotely or the user has the exact fallback material needed to create it manually. ## Step 7: Verify and report After creation, verify: - PR number - URL - title - state - draft status - base branch Also report: - whether uncommitted changes remain - whether the branch is ahead of remote - whether any warnings were carried into the PR process **Success criteria**: The user knows exactly what PR was created and any remaining branch caveats. ## Guardrails - Do not create PRs proactively. - Do not let the model invoke this skill through SkillTool; this workflow is intentionally user-only. - Do not add `paths:`. This is a generic workflow skill. - Do not add `context: fork`. PR state must stay in the active workspace. - Do not keep giant readiness checklists, scorecards, or failure catalogs inline in `SKILL.md`. - Do not fabricate test status, branch status, or breaking-change absence. ## When To Load References - `references/pr-conventions.md` Use for base-branch selection, classification heuristics, option parsing, and blocking rules. - `references/pr-body-examples.md` Use only when you need an example PR body shape for a similar request. ## Output Contract Report: 1. PR number, URL, title, base, and state 2. whether `commit` had to be invoked first 3. the checks run and any warnings that remained 4. any breaking changes documented 5. remaining working-tree or branch state
Related in General
modeling-omnistudio-epc-catalog
IncludedSalesforce Industries CME EPC product-modeling skill for Product2-based catalog creation. Use when creating EPC products, configuring product attributes, building offer bundles with Product Child Items, or reviewing EPC DataPack JSON metadata for product catalog changes. TRIGGER when: user creates or updates Product2 EPC records, AttributeAssignment payloads, AttributeMetadata/AttributeDefaultValues, Offer bundles, or ProductChildItem relationships. DO NOT TRIGGER when: designing OmniScripts/FlexCards/Integration Procedures (use building-omnistudio-omniscript, building-omnistudio-flexcard, or building-omnistudio-integration-procedure), implementing Apex business logic (use generating-apex), or troubleshooting deployment pipelines (use deploying-metadata).
relationship-science-coach
IncludedUse this skill for direct, practical adult relationship coaching: couples conflict, repair, trust, marriage, dating, flirting, attachment patterns, emotional connection, sex, desire differences, eroticism, kink negotiation, affection, love languages, breakups, and long-term passion. Draw on Gottman, EFT and Hold Me Tight, attachment science, modern sex research, Perel, Nagoski, Kerner, Schnarch, Love and Stosny, and flexible love-language tools. Be concrete and low-hedge. Redirect only for imminent danger, abuse, coercive control, minors, non-consent, self-harm, stalking, or medical/legal/psychiatric decisions.
building-sf-integrations
IncludedSalesforce integration architecture and runtime plumbing with 120-point scoring. Use this skill to set up Named Credentials, External Credentials, External Services, REST/SOAP callout patterns, Platform Events, and Change Data Capture. TRIGGER when: user sets up Named Credentials, External Services, REST/SOAP callouts, Platform Events, CDC, or touches .namedCredential-meta.xml files. DO NOT TRIGGER when: Connected App/OAuth config (use configuring-connected-apps), Apex-only logic (use generating-apex), or data import/export (use handling-sf-data).
venue-templates
IncludedAccess comprehensive LaTeX templates, formatting requirements, and submission guidelines for major scientific publication venues (Nature, Science, PLOS, IEEE, ACM), academic conferences (NeurIPS, ICML, CVPR, CHI), research posters, and grant proposals (NSF, NIH, DOE, DARPA). This skill should be used when preparing manuscripts for journal submission, conference papers, research posters, or grant proposals and need venue-specific formatting requirements and templates.
let-fate-decide
IncludedDraws the 12 Houses of the Zodiac Tarot spread to inject entropy into planning when prompts are vague, ambiguous, or casually delegated. Interprets the spread to guide next steps. Use when the user says 'let fate decide', 'YOLO', 'whatever', 'idk', or other nonchalant phrases, makes Yu-Gi-Oh references, or when you are about to arbitrarily pick between multiple reasonable approaches. Prefer over ask-questions-if-underspecified when the user's tone is casual or playful rather than precision-seeking.
net-ops
IncludedCross-platform network troubleshooting (Windows, macOS, Linux) via local or remote shell. Use for: DNS broken, can't resolve hostnames, nslookup/dig works but apps fail, NRPT, WFP, scutil, /etc/resolver, systemd-resolved, /etc/resolv.conf, NetworkManager, VPN DNS leak residue (ProtonVPN/Mullvad/WireGuard/AnyConnect), AV/firewall blocking DNS or DoH, Tailscale DNS interaction, intermittent connectivity, remote diagnostics over SSH.