Git & Ship — Quản lý code và deploy
Quản lý git workflow, tạo worktree cho parallel development, và ship code lên production.Cập nhật bộ claudekit mới: Thêm
/land-and-deploy (merge → deploy), /canary (post-deploy monitoring), /setup-deploy (config deploy platform), /ghpm (GitHub project management), /ship official|beta (tagged releases). Xem cấu trúc skill mới để biết đầy đủ.Cú pháp
Bảng tham chiếu nhanh
/git — Git operations
Hỗ trợ conventional commits tự động:/worktree — Parallel development
Cho phép chạy nhiều session Claude Code song song trên các bản sao riêng biệt của repo. Mỗi worktree có folder + branch riêng, không đụng nhau.Cách dùng
- Từ terminal
- Trong session Claude Code
- Cho subagent (Agent tool)
Lifecycle
- Không có thay đổi → worktree + branch tự xóa khi thoát
- Có thay đổi → Claude hỏi giữ lại hay xóa
File .worktreeinclude
Tạo ở root project, liệt kê file gitignored muốn copy vào worktree:
Use case cho project
Best practices:
- Đặt tên worktree theo branch convention:
feat-*,fix-*,hotfix-* - Tạo
.worktreeincludenếu project dùng.env - Dùng worktree khi cần chạy 2+ tasks song song trên cùng repo
- Không dùng worktree cho task nhỏ chỉ cần 1 session
/ship — Ship pipeline với release tags
Full pipeline từ feature branch đến production với semantic versioning tags:1
Bước 1: Merge main
Pull latest từ main/staging, resolve conflicts nếu có.
2
Bước 2: Test
Chạy full test suite — phải PASS 100%.
3
Bước 3: Review diff
Review toàn bộ changes so với base branch.
4
Bước 4: Commit + Push
Commit final, push lên remote.
5
Bước 5: Create Release
Tạo semantic version tag (v1.2.3 hoặc v1.2.3-beta.1).
6
Bước 6: Create PR + Merge
Tạo PR, merge tới main khi approved.
/land-and-deploy — Merge + Deploy + Monitor
Full pipeline từ PR merge đến production deployment:1
Bước 1: Merge PR
Merge feature branch → main (or staging).
2
Bước 2: Run CI/CD
Chạy full CI pipeline (tests, build, lint).
3
Bước 3: Deploy
Deploy to staging/production (auto-detect platform).
4
Bước 4: Health Check
Verify critical endpoints alive + responding.
5
Bước 5: Monitor
Watch error logs, performance metrics, user issues.
/canary — Post-deploy monitoring
Monitoring sau deploy, detect issues early:- Error rate (target: < 0.1%)
- Performance metrics (latency, throughput)
- Critical endpoint status
- User-facing issues
- Rollback trigger if needed
/setup-deploy — Config deploy platform
Cấu hình platform deploy cho project (chỉ cần 1 lần):- Vercel (Next.js, SvelteKit, static)
- Netlify (static, serverless functions)
- Fly.io (Docker)
- Railway (containers, databases)
- AWS (ECS, Lambda)
- GitHub Pages (static)
/ghpm — GitHub project management
Quản lý issues, PRs, project board, labels:- Auto-label issues theo title/description
- Move issues on project board (backlog → in progress → done)
- Create milestones + track progress
- Handoff status tracking
- Assign reviewers tự động
Branch naming convention
Khi nào dùng / không dùng
Chi tiết lệnh Git & Ship (Accordion)
/ship official — Release official version
/ship official — Release official version
Prefix: Output:
/ship officialFull pipeline với semantic versioning tag (v1.2.3):- Created tag:
v1.2.3 - Merged to main
- GitHub release page created
/ship beta — Release beta/pre-release
/ship beta — Release beta/pre-release
Prefix: Output:
/ship betaFull pipeline với beta tag (v1.2.3-beta.1):- Created tag:
v1.2.3-beta.1 - Merged to develop/staging
- GitHub pre-release page
/land-and-deploy — Merge + deploy end-to-end
/land-and-deploy — Merge + deploy end-to-end
Prefix: Steps:
/land-and-deployFull pipeline: merge PR → CI/CD → deploy → monitor:- Merge PR tới main
- Run full CI (tests, build, typecheck)
- Deploy to production
- Health check (endpoints, error rate)
- Monitor logs + metrics
/canary — Post-deploy health monitoring
/canary — Post-deploy health monitoring
Prefix: Checks:
/canaryMonitor deployment health after ship:- Error rate < 0.1%?
- Latency within SLA?
- Critical endpoints responding?
- User-facing errors detected?
/setup-deploy — Configure deploy platform
/setup-deploy — Configure deploy platform
Prefix: Detects + configures:
/setup-deployFirst-time setup for deployment platform:- Vercel (Next.js, SvelteKit)
- Netlify (static, serverless)
- Fly.io (Docker containers)
- Railway (managed containers)
- AWS (ECS, Lambda, CodeDeploy)
- GitHub Pages (static hosting)
.env, CI/CD files, deploy scripts.Khi dùng: New project, migrate to new platform, first-time ship./ghpm — GitHub project management
/ghpm — GitHub project management
Prefix: Actions:
/ghpmOrganize GitHub issues, PRs, project board:- Auto-label issues by type (bug, feature, enhancement)
- Move issues on kanban board
- Create milestones + track velocity
- Assign reviewers for PRs
- Track handoff status
- Generate project summary
/worktree — Parallel development in isolation
/worktree — Parallel development in isolation
Prefix: Benefits:
/worktree (already documented above, included for completeness)Create isolated git worktree for parallel development:- Multiple Claude Code sessions on same repo
- Independent branches, no conflicts
- Automatic cleanup when done