create-pull-request
について
このClaudeスキルは、GitHub CLIを使用してGitHubプルリクエストの作成と管理を自動化します。ブランチの準備、PRタイトル/説明の作成、PRの作成、レビュー/マージワークフローの管理を担当します。機能ブランチからの変更提案や、完了した作業のメインブランチへのマージを提案する際にご利用ください。
クイックインストール
Claude Code
推奨npx skills add pjt222/agent-almanac -a claude-code/plugin add https://github.com/pjt222/agent-almanacgit clone https://github.com/pjt222/agent-almanac.git ~/.claude/skills/create-pull-requestこのコマンドをClaude Codeにコピー&ペーストしてスキルをインストールします
ドキュメント
Create Pull Request
GitHub PR w/ clear title + structured desc + branch setup.
Use When
- Feature/fix branch → review
- Merge completed → main
- Req code review
- Doc purpose + scope of changes
In
- Required: Feature branch w/ committed changes
- Required: Base branch (usually
main) - Optional: Reviewers
- Optional: Labels / milestone
- Optional: Draft status
Do
Step 1: Branch Ready
Verify up-to-date + all committed:
# Check for uncommitted changes
git status
# Fetch latest from remote
git fetch origin
# Rebase on latest main (or merge)
git rebase origin/main
Got: Branch ahead of origin/main, no uncommit, no conflicts.
If err: Rebase conflicts → resolve (see resolve-git-conflicts) → git rebase --continue. Diverged → git merge origin/main.
Step 2: Review Changes
Full diff + commit history:
# See all commits on this branch (not on main)
git log origin/main..HEAD --oneline
# See the full diff against main
git diff origin/main...HEAD
# Check if branch tracks remote and is pushed
git status -sb
Got: All commits PR-relevant. Diff = intended changes only.
If err: Unrelated commits → interactive rebase → clean up history pre-PR.
Step 3: Push Branch
# Push branch to remote (set upstream tracking)
git push -u origin HEAD
Got: Branch on GitHub remote.
If err: Rejected → git pull --rebase origin <branch> + resolve.
Step 4: Title + Desc
Title <70 chars. Body for details:
gh pr create --title "Add weighted mean calculation" --body "$(cat <<'EOF'
## Summary
- Implement `weighted_mean()` with NA handling and zero-weight filtering
- Add input validation for mismatched vector lengths
- Include unit tests covering edge cases
## Test plan
- [ ] `devtools::test()` passes with no failures
- [ ] Manual verification with example data
- [ ] Edge cases: empty vectors, all-NA weights, zero-length input
🤖 Generated with [Claude Code](https://claude.com/claude-code)
EOF
)"
Draft:
gh pr create --title "WIP: Add authentication" --body "..." --draft
Got: PR on GitHub + URL. Desc = what changed + how to test.
If err: gh not auth → gh auth login. Wrong base → --base main.
Step 5: Review Feedback
Respond + push:
# View PR comments
gh api repos/{owner}/{repo}/pulls/{number}/comments
# View PR review status
gh pr checks
# After making changes, commit and push
git add <files>
git commit -m "$(cat <<'EOF'
fix: address review feedback on input validation
EOF
)"
git push
Got: New commits on PR. Comments addressed.
If err: CI fail post-push → gh pr checks → fix pre-rereq.
Step 6: Merge + Cleanup
Post-approval:
# Merge the PR (squash merge keeps history clean)
gh pr merge --squash --delete-branch
# Or merge with all commits preserved
gh pr merge --merge --delete-branch
# Or rebase merge (linear history)
gh pr merge --rebase --delete-branch
Update local main:
git checkout main
git pull origin main
Got: PR merged, remote branch deleted, local main updated.
If err: Blocked by fail checks / missing approvals → address first. No force-merge w/o resolve.
Check
- Title <70 chars + descriptive
- Body: summary + test plan
- All commits PR-relevant
- CI passes
- Branch up-to-date vs base
- Reviewers assigned (if req)
- No sensitive data
Traps
- PR too large: Focus 1 feat/fix. Large → hard review + merge conflicts.
- No test plan: Always describe verify, even docs.
- Stale branch: Base moved ahead → rebase pre-PR → min conflicts.
- Force-push during review: Avoid on branch w/ open comments. Push new → incremental visible.
- Ignoring CI: Check
gh pr checkspre-rereq. Fail CI = waste reviewers. - Branch not deleted: Use
--delete-branch→ remote clean.
→
commit-changes— PR commitsmanage-git-branches— branch create + namingresolve-git-conflicts— rebase/merge conflictscreate-github-release— release post-merge
GitHub リポジトリ
関連スキル
content-collections
メタこのスキルは、Content Collections(Markdown/MDXファイルを型安全なデータコレクションに変換するTypeScriptファーストのツール)の本番環境でテストされた設定を提供します。Zodバリデーションによる型安全性を実現し、ブログ、ドキュメントサイト、コンテンツ重視のVite + Reactアプリケーション構築時にご利用ください。Viteプラグインの設定、MDXコンパイルから、デプロイ最適化、スキーマバリデーションまで、すべてを網羅しています。
polymarket
メタこのスキルは、開発者がPolymarket予測市場プラットフォームを活用したアプリケーション構築を可能にします。API統合による取引や市場データの取得に加え、WebSocketを介したリアルタイムデータストリーミングにより、ライブ取引や市場活動を監視できます。取引戦略の実装や、ライブ市場更新を処理するツールの作成にご利用ください。
creating-opencode-plugins
メタこのスキルは、開発者がコマンド、ファイル、LSP操作など25種類以上のイベントタイプにフックするOpenCodeプラグインを作成することを支援します。JavaScript/TypeScriptモジュール向けに、プラグイン構造、イベントAPI仕様、および実装パターンを提供します。カスタムイベント駆動ロジックでOpenCode AIアシスタントのライフサイクルをインターセプト、監視、または拡張する必要がある場合にご利用ください。
sglang
メタSGLangは、高性能なLLMサービングフレームワークであり、RadixAttentionプレフィックスキャッシュを活用したJSON、正規表現、エージェントワークフロー向けの高速で構造化された生成を特長とします。特にプレフィックスが繰り返されるタスクにおいて、大幅に高速な推論を実現し、複雑な構造化出力やマルチターン対話に最適です。制約付きデコードが必要な場合や、広範なプレフィックス共有を伴うアプリケーションを構築する場合は、vLLMなどの代替案ではなくSGLangを選択してください。
