From git-workflow
Automates Git workflow from branch creation to PR: generates branches from latest base/develop/main, commits with co-authors, pushes, creates/updates GitHub PRs using shell scripts. Use for quick feature-to-PR cycles.
How this skill is triggered — by the user, by Claude, or both
Slash command
/git-workflow:git-workflowThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
ブランチ作成 → コミット → PR作成 までのGitワークフローを支援する。
ブランチ作成 → コミット → PR作成 までのGitワークフローを支援する。
すべての操作は .claude/skills/git-workflow/scripts/ のシェルスクリプトを使用すること。
| スクリプト | 用途 | 例 |
|---|---|---|
full-workflow.sh | (新ブランチ →) commit → push → PR | .claude/skills/git-workflow/scripts/full-workflow.sh "msg" "title" "body" [branch] |
create-branch.sh | ブランチ作成(最新 pull + 自動検出) | .claude/skills/git-workflow/scripts/create-branch.sh feat/add-login |
commit.sh | コミット(Co-Author 付き) | .claude/skills/git-workflow/scripts/commit.sh "feat(web): add login" |
create-pr.sh | PR作成(base: 自動検出) | .claude/skills/git-workflow/scripts/create-pr.sh "title" "body" |
/git-workflow <command> [options]
| Command | 説明 | 例 |
|---|---|---|
| (なし) | フルワークフロー: commit → push → PR | /git-workflow |
branch | 新しいブランチを作成 | /git-workflow branch feat/add-login |
commit | ステージした変更をコミット | /git-workflow commit |
pr | PRを作成 | /git-workflow pr |
引数なしで /git-workflow を実行した場合、以下を ノンストップで自動実行 する:
git status で変更を確認git add).claude/skills/git-workflow/scripts/full-workflow.sh を実行# 現在のフィーチャーブランチからそのままコミット → push → PR
.claude/skills/git-workflow/scripts/full-workflow.sh "<commit message>" "<pr title>" "<pr body>"
# 新しいブランチを切ってからコミット → push → PR(main/develop にいるとき、または別ブランチから独立させたいとき)
.claude/skills/git-workflow/scripts/full-workflow.sh "<commit message>" "<pr title>" "<pr body>" "feat/new-feature"
スクリプトが自動で以下を実行:
git fetch origin でリモートの最新を取得.claude/skills/git-workflow/scripts/create-branch.sh を実行# ベースブランチから最新を pull して新しいブランチを作成
.claude/skills/git-workflow/scripts/create-branch.sh <branch-name>
スクリプトが自動で以下を実行:
git fetch origin でリモートの最新を取得develop ブランチが存在するか確認 → なければ main をベースにgit pull<type>/<short-description>
| Type | 用途 | 例 |
|---|---|---|
feat | 新機能 | feat/add-user-auth |
fix | バグ修正 | fix/login-error |
refactor | リファクタリング | refactor/api-structure |
docs | ドキュメント | docs/api-readme |
chore | 雑務・設定 | chore/update-deps |
perf | パフォーマンス改善 | perf/optimize-queries |
update | 既存機能の改善 | update/improve-logging |
develop があれば develop、なければ maingit status でステージされた変更を確認git diff --cached で変更内容を分析.claude/skills/git-workflow/scripts/commit.sh を実行# Co-Authored-By 付きでコミット
.claude/skills/git-workflow/scripts/commit.sh "<commit message>"
<type>(<scope>): <subject>
| Type | 説明 | 例 |
|---|---|---|
feat | 新機能追加 | 新しいAPI、コンポーネント |
fix | バグ修正 | エラー修正、不具合対応 |
docs | ドキュメントのみ | README、コメント |
style | コードスタイル | フォーマット、セミコロン |
refactor | リファクタリング | 機能変更なしの改善 |
perf | パフォーマンス改善 | 速度向上、最適化 |
test | テスト | テスト追加・修正 |
chore | 雑務 | ビルド、依存関係、設定 |
ci | CI/CD | GitHub Actions等 |
revert | リバート | 過去コミットの取消 |
| Scope | 対象 |
|---|---|
server | packages/server |
web | packages/web |
shared | packages/shared |
db | データベース関連 |
api | APIエンドポイント |
ui | UIコンポーネント |
config | 設定ファイル |
| ファイルパス | Scope |
|---|---|
packages/server/** | server |
packages/web/** | web |
packages/shared/** | shared |
**/db/**, *.db | db |
**/routes/**, **/api/** | api |
**/components/** | ui |
*.config.*, tsconfig.* | config |
docs/**, *.md | (scopeなし、type: docs) |
**/*.test.*, **/__tests__/** | (scopeなし、type: test) |
スクリプトが develop の存在を確認し、なければ main をベースに PR を作成する。
git log と git diff <base>...HEAD で変更内容を分析(base はスクリプトが自動検出).claude/skills/git-workflow/scripts/create-pr.sh を実行# PR作成(push も含む、base は自動検出)
.claude/skills/git-workflow/scripts/create-pr.sh "<title>" "<body>"
コミットメッセージと同様、Conventional Commits形式:
<type>(<scope>): <short description>
IMPORTANT: All PR content (title, summary, test plan) MUST be written in English.
## Summary
- Brief description of changes (1-3 bullet points, in English)
## Test plan
- [ ] Test item 1
- [ ] Test item 2
🤖 Generated with [Claude Code](https://claude.com/claude-code)
.claude/skills/git-workflow/scripts/commit.sh "feat(api): add user authentication endpoint"
.claude/skills/git-workflow/scripts/commit.sh "feat(web): add session management with SQLite
- Implement Drizzle ORM for database operations
- Add session CRUD endpoints
- Create sidebar component for session list"
.claude/skills/git-workflow/scripts/commit.sh "fix(server): resolve streaming timeout issue
Fixes #42"
npx claudepluginhub sean-sunagaku/claude-code-plugin --plugin git-workflowAutomates GitHub workflow: branching, committing, pushing, PRs, issues, and code review. Use when managing git operations or GitHub development lifecycle.
Guides Git operations with Conventional Commits, PR formats, workflows including local CI and squash merges. Use for commits, branches, pull requests, and merge conflicts.
Creates GitHub Pull Requests using GitHub CLI: detects existing PRs for branches, pushes changes, generates titles/bodies from commits. Handles monorepos/submodules. Use for /create-pr or PR/review requests.