一键导入
git
Git operations including commits, branches, worktrees, and safety protocols. Use on 'git', 'commit', 'branch', 'worktree', 'rebase', 'merge'.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Git operations including commits, branches, worktrees, and safety protocols. Use on 'git', 'commit', 'branch', 'worktree', 'rebase', 'merge'.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
Airflow DAG patterns, KubernetesPodOperator, and debugging. Use on 'dag', 'airflow', 'task', 'operator', 'KPO', 'scheduler', 'XCom'.
Create and debug AWS IAM policies with least-privilege. Use on 'IAM policy', 'permission denied', 'access denied', 'not authorized', 'create role'.
Create architecture diagrams with draw.io MCP server. Use on 'diagram', 'architecture', 'drawio', 'flowchart', 'visualize'.
Helm chart policies, bitnami legacy repo, and release management. Use on 'helm-skill' or 'load helm skill'.
Kubernetes security best practices for manifests and Helm charts. Use on 'k8s security', 'manifest audit', 'helm security review', 'pod hardening'.
Build Python/K8s/AWS with minimal code. Every line is a liability. Use on 'build', 'implement', 'add', 'create', 'deploy'. Prioritizes deletion, reuse, and configuration over new code.
基于 SOC 职业分类
| name | git |
| description | Git operations including commits, branches, worktrees, and safety protocols. Use on 'git', 'commit', 'branch', 'worktree', 'rebase', 'merge'. |
Safe, consistent git operations for agents.
These rules are NON-NEGOTIABLE:
git status showing "Your branch is ahead"--no-verify or --no-gpg-sign.env, credentials.json, *.key, *.pemgit push AND gh pr create. Creating PRs is equivalent to pushing.Format: <type>(<scope>): <description>
| Type | When to Use |
|---|---|
feat | New feature |
fix | Bug fix |
docs | Documentation only |
style | Formatting, no code change |
refactor | Code change, no feature/fix |
perf | Performance improvement |
test | Adding/fixing tests |
chore | Build, tooling, deps |
ci | CI/CD changes |
revert | Reverting previous commit |
Rules:
feat(auth): add login endpoint# 1. Check state
git status
# 2. Review changes
git diff # unstaged
git diff --cached # staged
# 3. Stage files (prefer explicit over `git add .`)
git add <specific-files>
# 4. Commit with conventional message
git commit -m "type(scope): description"
# 5. Verify
git log -1
git status
# 6. DO NOT PUSH - leave for user
# Check current branch
git branch --show-current
# Create feature branch
git checkout -b feat/short-description
# Create from specific base
git checkout -b fix/bug-description main
Branch naming conventions:
feat/ - new featuresfix/ - bug fixeschore/ - maintenancerefactor/ - code restructuringdocs/ - documentationContext-dependent - choose based on situation:
| Use Rebase | Use Merge |
|---|---|
| Cleaning local commits before PR | Preserving branch history |
| Linear history preferred | Shared branch with others |
| Feature branch behind main | Main into feature (public branch) |
NEVER rebase pushed commits unless user explicitly requests it (requires force push).
Before ANY destructive operation (reset --hard, push --force, rebase -i, commit --amend):
git status?If ANY checkbox is unclear, ask the user first.
Convention: worktrees go in ./tree/ directory.
# List worktrees
git worktree list
# Add worktree for existing branch
git worktree add ./tree/feat-branch feat-branch
# Add worktree with new branch
git worktree add -b fix/new-fix ./tree/fix-new-fix main
# Remove worktree
git worktree remove ./tree/old-branch
# Clean up stale entries
git worktree prune
Only use git commit --amend when ALL conditions are met:
git log -1 --format='%an %ae')git status shows "Your branch is ahead")If commit FAILED or was REJECTED by hook - NEVER amend. Fix the issue and create a NEW commit.
# Status and history
git status
git log --oneline -10
git diff HEAD~1
# Undo last commit (keep changes)
git reset --soft HEAD~1
# Discard unstaged changes (DANGEROUS)
git checkout -- <file>
# Stash work temporarily
git stash
git stash pop
# Check remote state
git fetch --dry-run
git log origin/main..HEAD