Automated summary
Automates creating a pull request from the current branch: formatting, committing, rebasing onto origin/main, passing the local CI gate, then opening the PR.
Strengths
- Orders the steps correctly: the rebase onto origin/main happens before the CI gate, so the check reflects the true merge result
- Detects the `reviewed`/`skip-review` arguments and the absence of Swift files to avoid running code review twice
- Scales the local gate to the diff: full `make ci` when code changes, otherwise lint + markdown + docs only
- Verifies no secrets, `.env` files, or build artifacts slip into the commit
- Rebasing onto origin/main rather than local main makes it worktree-safe
Limitations
- Assumes a specific toolchain (a Makefile exposing `make ci`, `lint`, `lint-markdown`, `build-docs`) plus in-house commands like `/format`
- Heavily Swift/Xcode-oriented: the diff-detection and review rules only apply to that kind of repository
- Stops at the first failure and may require `git push --force-with-lease` after rebasing an already-pushed branch
Use it when a feature branch is ready and you want a clean, rebased PR that has passed the local CI gate in one command.
Avoid it on a repository that does not use the expected Makefile targets and gitmoji commit convention, or when no local code review is wanted.
Security analysis
CautionThe skill instructs standard, legitimate development workflow commands for formatting, committing, rebasing, testing, and pushing a pull request. No destructive or exfiltrating actions are present; it even includes a step to verify no secrets or build artifacts are committed. However, the use of rebase and force-with-lease push, along with running build/test commands, warrants a caution rating due to the potential for history rewriting and remote branch overwrite if not handled carefully.
- •Uses git rebase and force-with-lease push, which rewrite branch history and can overwrite remote refs if misused.
- •Runs local CI commands (make ci, swiftlint) and network git operations (fetch, push).
Examples
/pr/pr reviewedCreate a pull request for the current branch — rebase on origin/main, run the CI gate first, and skip the code review if it already ran.name: pr description: Create a pull request
Create a pull request
I'll create a pull request for the current branch by following these steps. If any steps fail, stop.
Mode — check the arguments passed to this skill (shown at the end). If they
include reviewed (or skip-review), an upstream step already ran the
code-reviewer and fixed its findings (e.g. /deliver's code-review phase), so
skip steps 5–7 to avoid reviewing identical code twice. Otherwise (standalone
/pr), run the internal review as normal.
Also skip steps 5–7 when the branch changes no Swift — code review is for Swift, so a docs-only / config-only PR needs none:
git diff --name-only origin/main...HEAD | grep -qE '\.swift$' || echo "no-swift → skip review"
-
Run
/formatto format code -
Commit all outstanding work. Run
git status. If the working tree has any uncommitted or unstaged changes (the feature work, plus the formatting from step 1), stage and commit them — the PR reflects committed history only, so anything left uncommitted will be missing from the PR. First verify no secrets,.env, or build artifacts are included (per CLAUDE.md —.envmust stay gitignored; checkgit statusbeforegit add). Use a descriptive gitmoji message (or several logical commits if the work spans concerns); formatting-only changes can use "🎨 apply code formatting". If the tree is already clean (e.g. work was committed during/deliver), this is a no-op. -
Rebase onto the latest
origin/main. Fetch the remote and rebase the feature branch directly ontoorigin/main— do this beforemake ciso the gate (and the eventual PR) reflects the real merge result, not stale code:git fetch origin git rebase origin/main- Rebase onto
origin/main, not localmain— this is worktree-safe. A/deliverruns inside a git worktree, andgit checkout mainthere fails (fatal: 'main' is already used by worktree …) whenever the main checkout is onmain; rebasing ontoorigin/mainavoids checkingmainout at all and uses the true remote base directly. - If
git rebasereports conflicts, stop, resolve them, then continue. Never skip or force past a conflict you don't understand. - The rebase rewrites the branch tip, so a branch that was already pushed will need
git push --force-with-leaseat the push step below. - Already branched off an up-to-date
origin/mainwith nothing to replay → this is a fast no-op.
- Rebase onto
-
Run the pre-PR gate — MANDATORY; it must pass before going further. Run it directly (do not delegate). If it fails, stop and fix — commit the fixes — then re-run; never open a PR on a red gate. Scale the gate to the diff:
-
Default — full
make ci. The gate CLAUDE.md requires before any PR: lint, markdown lint, unit tests, integration tests, the release build, and the docs build. Use this whenever any code or build-affecting file changed. -
Docs/config-only fast gate. When the diff touches no build- or test-affecting files — i.e. no
*.swiftand none ofMakefile,Package.swift,Package.resolved,*.xctestplan, or.github/workflows/**— the test/release-build legs ofmake cihave nothing to exercise. Run only the meaningful checks instead:make lint && make lint-markdown && make build-docs(dropbuild-docsif no*.docc/**changed). Detect this with:git diff --name-only origin/main...HEAD \ | grep -qE '\.swift$|^Makefile$|^Package\.(swift|resolved)$|\.xctestplan$|^\.github/workflows/' \ && echo "code/build touched → full make ci" \ || echo "docs/config-only → fast gate"The PR's own CI still runs the full matrix regardless, so this only trims the local gate; it never lowers what actually guards
main. When in doubt, run fullmake ci. -
Re-lint new Swift files without the cache.
make ci's lint leg isswiftlint --strict .(Makefile), and SwiftLint caches results (~/Library/Caches/SwiftLint). On newly-added.swiftfiles this has been seen to report a false green locally — passingfile_length/type_body_lengththat the PR's CILintjob (a clean checkout, no cache) then fails on. So when the diff adds any new.swiftfile (git diff --name-only --diff-filter=A origin/main...HEAD | grep -q '\.swift$'), run a cache-bypassing lint before trusting the gate:swiftlint lint --strict --no-cache .Fix anything it flags (oversized files: split, or add a
// swiftlint:disabledirective matching theAccountService+Pagination.swiftprecedent) and re-run. This catches file-size violations locally instead of on a CI round-trip.
-
-
(skip in
reviewedmode or when no Swift changed) Spawn thecode-revieweragent to perform a code review of all changes (pass the git diff output as context) -
(skip in
reviewedmode or when no Swift changed) Summarize the code review findings:- List any critical or high-severity issues that should be addressed
- List any medium-severity suggestions for improvement
- Note any low-severity or stylistic recommendations
-
(skip in
reviewedmode or when no Swift changed) If there are critical/high-severity issues:- Recommend specific changes needed
- Ask user for confirmation before proceeding (fix issues or continue anyway)
- If user wants to fix issues, stop and let them address the feedback
-
Ensure a clean working tree before pushing. Re-run
git status; commit anything still outstanding (e.g. review fixes from steps 5–7, ormake cifixes) so the push includes everything. The tree must be clean before proceeding. Then rungit diff origin/main...HEADto understand all changes going into the PR. -
Analyze the commits and changes to generate an appropriate title and summary
-
Push the current branch to remote (
git push -u origin <branch>if not yet pushed; otherwisegit push— usegit push --force-with-leaseif you rebased in step 3) -
Create a PR with the GitHub MCP —
mcp__github__create_pull_request(owner/repo from theoriginremote,base: main,head: <branch>, plustitle/body). The branch must already be pushed (step 10). If the call fails with 401/403 (PAT expired or missing scope), fall back togh pr createwith the same title/body.Title — MUST start with a gitmoji prefix matching the change:
| Emoji | Code | Use for | |-------|------|---------| | ✨ |
:sparkles:| New features | | 🐛 |:bug:| Bug fixes | | 📝 |:memo:| Documentation updates | | ♻️ |:recycle:| Refactoring | | ✅ |:white_check_mark:| Adding/updating tests | | 🔧 |:wrench:| Configuration changes | | ⚡️ |:zap:| Performance improvements | | 🎨 |:art:| Code style/formatting |Example:
✨ Add createdBy property to TVSeries.Body — fill this skeleton, keeping only the sections that apply, and end with the attribution line exactly as shown:
## Summary [Brief description of what this PR does and why] ## Changes **New Model/Feature/Component:** - ✨ [Description] **Existing Files:** - 📝 [Description] **Tests:** - ✅ [Description of test coverage] **Documentation:** - 📚 [Description] ## Benefits - **[Benefit Category]**: [Description] 🤖 Generated with [Claude Code](https://claude.com/claude-code)
$ARGUMENTS
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-a-pull-request-ms47vnyg/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-a-pull-request-ms47vnyg' && curl --fail --show-error --location 'https://skills-guides.com/api/skills/create-a-pull-request-ms47vnyg/download' --output '.skill-downloads/create-a-pull-request-ms47vnyg/SKILL.md.part' && mv '.skill-downloads/create-a-pull-request-ms47vnyg/SKILL.md.part' '.skill-downloads/create-a-pull-request-ms47vnyg/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
After inspection, copy the complete folder into your project using one of the commands below, then open a new tool session. The command stops if a folder with the same name already exists: compare the files before replacing it.
Claude Code
test -f '.skill-downloads/create-a-pull-request-ms47vnyg/SKILL.md' && test -s '.skill-downloads/create-a-pull-request-ms47vnyg/SKILL.md' && mkdir -p '.claude/skills' && test ! -e '.claude/skills/pr' && cp -R '.skill-downloads/create-a-pull-request-ms47vnyg' '.claude/skills/pr'OpenSkills
OpenSkills must already be installed. The local install/read procedure is checked with OpenSkills 1.5.0, which requires Node.js ≥ 20.6.0. Catalog slugs are not resolved automatically.
Official OpenSkills installationopenskills install './.skill-downloads/create-a-pull-request-ms47vnyg'openskills read 'create-a-pull-request-ms47vnyg'Reading should display the installed file content and its base directory. It does not run the skill or install its dependencies.
For an agent that reads AGENTS.md, then sync the index. This command changes AGENTS.md: review the diff before using it.
openskills syncManual 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-a-pull-request-ms47vnyg/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.