github-cli
Skill1 starsChanged 7 months agoMITView on GitHub
GitHub操作にはGitHub CLI(gh)を使用。MCPプラグインは使用しない。PR作成・マージ、Issue管理、レビュー確認など。/pr-flowコマンドで完全なPRフローを実行可能。 トリガー: "github", "gh", "PR作成", "issue管理", "プルリクエスト", "レビュー確認"
- Deletes or force-pushes
- Commits and pushes
25 other projects use a version of this.
Adopted by
Most recently taken up by
- himkt/configtheir own version, first seen Nov 7, 2026
- rogue-dev-studio/ai-agents-roguetheir own version, first seen Nov 1, 2026
- kuailexiaozixin/githubtheir own version, first seen Oct 24, 2026
- Anish29801/cursor-plugin-github-clitheir own version, first seen Oct 20, 2026
- danilolucasmd/skillstheir own version, first seen Oct 19, 2026
- garri333/Skillstheir own version, first seen Oct 11, 2026
Used with
Projects with it also use terraform, codex-cli and 3 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
ihiteshguptaSkillterraform
Expert in Infrastructure as Code with Terraform. Use for creating, managing, and versioning infrastructure across cloud providers.
Also in 3 projects that use this
garri333Skillcodex-cli
OpenAI Codex CLI mastery skill for installation, authentication, terminal commands, code generation from natural language, file editing, project scaffolding, and IDE integrations. Covers GPT-5.2 Instant/Thinking tiers and shell/container execution modes.
Also in 3 projects that use this
PostHogSkillkarpathy-guidelines
Behavioral guidelines to reduce common LLM coding mistakes. Use when writing, reviewing, or refactoring code to avoid overcomplication, make surgical changes, surface assumptions, and define verifiable success criteria. Based on https://github.com/multica-ai/andrej-karpathy-skills.
Also in 3 projects that use this
MicrosoftSkillcaveman
Ultra-compressed response style that reduces output token count while preserving technical accuracy, with intensity levels and auto-clarity safety rules
Also in 3 projects that use this
BlockSkillfrontend-design
Create distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
Also in 4 projects that use this
Other versions25 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 25
- kaeawc/auto-mobile★ 56same name
- himkt/config★ 40same name
- georgekhananaev/claude-skills-vault★ 28same name
- doug-skinner/github-cli-claude-skill★ 10same name
- abdullahkhawer/devops-skills★ 8same name
- jonhill90/skills★ 8same name
- trotsky1997/My-Claude-Agent-Skills★ 7same name
- magnusrodseth/dotfiles★ 3same name
- shalomb/agent-skills★ 3same name
- aaronflorey/agent-skills★ 2same name
15 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository66 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- agent-teams-codingSkill
- AI External Brain (Knowledge Base)Skill
- awesome-design-md-jpSkill
- awesome-design-mdSkill
- softbank-invoiceSkill
- claude-for-chromeSkill
- codebase-patrolSkill
- codex-autopilotSkill
- codexSkill
- Context7 Documentation LookupSkill
- design-review-checklistSkill
- detail-design-docSkill
- discord-promotionSkill
- drawioSkill
- e2e-testSkill
- fish-audio-apiSkill
- fish-audio-docsSkill
- fish-audioSkill
- fortress-implementSkill
- fortress-reviewSkill
- freee Developer APISkill
- frontend-skillSkill
- gBizINFO APISkill
- git-worktree-parallelSkill
- google-sheets-apiSkill
- google-sheets-mcpSkill
- graphify-windowsSkill
- issue-autopilot-batchSkill
- issue-flowSkill
- issue-plannerSkill
- Jグランツ APISkill
- Knip - Dead Code DetectionSkill
- liftkitSkill
- llm-vulnerability-testSkill
- MarkItDownSkill
- mba-strategy-consultantSkill
- Obsidian CLI OperationsSkill
- openrouterSkill
- PAY.JP CLI OperationsSkill
- playwright-cliSkill
- playwrightSkill
- qwen-coderSkill
- ryokan-forecastSkill
- security-adversarialSkill
- security-settingsSkill
- skill-improveSkill
- stoic-daily-practiceSkill
- Stripe CLI OperationsSkill
- Stripe PayPay決済Skill
- Supabase CLI OperationsSkill
- tile-terminalsSkill
- timesfmSkill
- ui-ux-pro-maxSkill
- usacon-account-mgmtSkill
- usacon-cliSkill
- usacon-discordSkill
- usacon-partner-registrationSkill
- usaconSkill
- ux-psychologySkill
- The first 60 shown.
The file
Files
GitHub CLI ガイド
概要
GitHub操作にはGitHub CLI(ghコマンド)を使用。MCPプラグインは使用しない。
インストール確認
gh --version
# 認証状態確認
gh auth status基本コマンド
PR操作
# PR一覧(オープン中)
gh pr list --state open
# PR作成
gh pr create --title "タイトル" --body "説明"
# PR詳細確認
gh pr view <PR番号>
# PRの変更ファイル一覧
gh pr diff <PR番号> --name-only
# PRチェック状態(CI/CD)
gh pr checks <PR番号>
# PRチェック完了まで待機(自動更新)
gh pr checks --watch
# PRマージ(squash + ブランチ削除)
gh pr merge --squash --delete-branchIssue操作
# Issue一覧
gh issue list
# Issue作成
gh issue create --title "タイトル" --body "説明"
# Issue詳細
gh issue view <Issue番号>Issue内の画像取得
GitHub Issueに添付された画像(https://github.com/user-attachments/assets/...)は認証が必要。
WebFetchやPlaywright(未ログイン)では404になるため、認証付きCLIで取得する。
# 1. Issue本文から画像URLを抽出
URLS=$(gh issue view <Issue番号> --json body -q '.body' | grep -oP 'https://github\.com/user-attachments/assets/[a-f0-9-]+')
# 2. 保存先ディレクトリを作成(Windowsパス — /tmp はRead toolで読めない)
mkdir -p "C:/Users/zooyo/tmp-issue-images"
# 3. 方法A: gh api(推奨・まずこちらを試す)
i=1
for url in $URLS; do
gh api -H "Accept: application/octet-stream" "$url" > "C:/Users/zooyo/tmp-issue-images/issue-<Issue番号>-${i}.png"
i=$((i+1))
done
# 4. サイズ検証(9バイト等の場合はリダイレクト応答なので方法Bへ)
ls -la C:/Users/zooyo/tmp-issue-images/
# 5. 方法B: curl + gh auth token(gh apiが9バイト等を返した場合のフォールバック)
TOKEN=$(gh auth token)
i=1
for url in $URLS; do
curl -sL -H "Authorization: token $TOKEN" -H "Accept: application/octet-stream" \
-o "C:/Users/zooyo/tmp-issue-images/issue-<Issue番号>-${i}.png" "$url"
i=$((i+1))
done
# 6. Read toolで画像を確認(マルチモーダル表示)
# Read file_path="C:\Users\zooyo\tmp-issue-images\issue-<Issue番号>-1.png"
# 7. 確認後クリーンアップ
rm -rf C:/Users/zooyo/tmp-issue-images/注意事項:
--repoオプションでリポジトリ指定すればcd不要:gh issue view 123 --repo owner/repo --json body- 必ずファイルサイズを検証する — 数バイト〜数十バイトの場合はリダイレクト応答(方法Bで再取得)
- PR本文の画像も同じ手法で取得可能
リポジトリ操作
# リポジトリ情報
gh repo view
# クローン
gh repo clone <owner>/<repo>/pr-flow カスタムコマンド
/pr-flow は llm ブランチでの開発完了後、mainブランチへマージするまでの完全フローを実行する。
フロー概要
1. 事前確認(コンフリクトチェック)
↓
2. mainブランチから最新をpull
↓
3. 変更をコミット & プッシュ
↓
4. PR作成(まだない場合)
↓
5. CodeRabbitレビュー待機(gh pr checks --watch)
↓
6. 修正(必要な場合)
↓
7. ユーザー承認後マージ(gh pr merge --squash)コンフリクト予防の鉄則
| ルール | 説明 |
| 作業開始前 | mainを最新にpull → llm新規作成 |
| PR作成後 | すぐにマージ(差分最小化) |
| mainブランチ | コード変更は絶対にしない |
| 重複チェック | オープンPRと修正ファイルの重複を確認 |
PR作成前チェックスクリプト
# 全オープンPRの修正ファイルを確認
echo "=== オープン中のPR一覧 ==="
gh pr list --state open
# 各PRの修正ファイルを表示
for pr in $(gh pr list --state open --json number -q '.[].number'); do
echo ""
echo "=== PR #$pr の修正ファイル ==="
gh pr diff $pr --name-only
doneコンフリクト発生時の解決
# 頻繁にコンフリクトするファイル対策
# 1. ESLintログ等の自動生成ファイル → 自分のを採用
git checkout --ours <file>
# 2. 自分が触っていないファイル → mainのを採用
git checkout --theirs <file>
# 3. 両方に変更があるファイル → 手動マージ
# コンフリクトマーカーを編集
# 解決後
git add .
git commit -m "Merge branch 'main' into llm"ブランチ運用ルール
開発開始時(毎回実行)
git checkout main
git pull origin main
git checkout -b llm # 毎回新規作成mainで作業してしまった場合(緊急対応)
git stash save "WIP: 作業内容"
git pull origin main
git checkout -b llm
git stash pop
# コンフリクト発生時は手動解決注意事項
- mainブランチへの直接コミット禁止
- PRマージ前に必ずユーザー承認を得る
- CodeRabbitの指摘は必ず修正
- 古いllmブランチは使い回さない(毎回新規作成)
チェックリスト
- PR作成前にオープン中のPRと修正ファイルの重複を確認したか
- baseブランチを正しく指定したか(staging/main)
- CodeRabbitレビューのPRコメントを読んだか
トラブルシューティング
| 症状 | 原因 | 対処 |
gh auth エラー | 認証トークン期限切れ | gh auth login で再認証 |
| PR作成時にbase指定忘れ | デフォルトブランチがmain | --base staging を明示 |
gh pr checks がタイムアウト | CIが長い | --watch + バックグラウンド実行 |
関連スキル
- usacon — PR作成・マージの完全フロー(staging経由)
- issue-flow — Issue実装ワークフローでの
ghコマンド活用 - vercel-watch — PRマージ後のデプロイ監視
参考
- GitHub CLI公式: https://cli.github.com/
- gh pr checks --watch: https://zenn.dev/hankei6km/articles/pull-request-with-github-cli
改訂履歴
| 日付 | 変更内容 | 変更理由 |
| 2026-03-04 | 横断テンプレート適用(トリガー、チェックリスト、トラブルシューティング、関連スキル、改訂履歴追加) | スキル品質改善計画 |
| 2026-02-15 | 初版作成 | GitHub CLI操作の標準化 |
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

