技能 managing-branches
🔀

managing-branches

安全 ⚙️ 外部命令

调查并创建 Git 分支

也可從以下取得: C0ntr0lledCha0s,1gy

管理 Git 分支可能会令人困惑,尤其是在处理错误或同步问题时。此技能可自动化分支调查与创建,同时处理冲突和未提交更改等常见问题。

支援: Claude Codex Code(CC)
📊 71 充足
1

下載技能 ZIP

2

在 Claude 中上傳

前往 設定 → 功能 → 技能 → 上傳技能

3

開啟並開始使用

測試它

正在使用「managing-branches」。 Check the current branch status

預期結果:

  • Current branch: feature/new-api
  • Uncommitted changes: 3 files modified
  • Remote sync: 2 commits ahead of main
  • Remote branches: origin/main is up to date
  • Recommended action: Consider committing or stashing changes before continuing

正在使用「managing-branches」。 Create a feature branch from main

預期結果:

  • Fetching latest changes from origin main
  • Creating new branch feature/user-auth from main
  • Branch created successfully
  • Switched to new branch feature/user-auth
  • No conflicts detected during creation

安全審計

安全
v3 • 1/16/2026

This is a prompt-based Git utility skill with no malicious code. The static scanner incorrectly flagged multiple findings: the 'weak cryptographic algorithm' detections are false positives (the scanner misidentified strings like 'managing-branches' and 'Quick branch status check' as crypto references). The 'external_commands' findings show standard Git commands (git branch, git status, git checkout) that are safe for a branch management skill. The 'filesystem' and 'network' findings are metadata strings, not actual access calls. The skill only uses safe Git commands and does not perform destructive operations.

2
已掃描檔案
262
分析行數
1
發現項
3
審計總數

風險因素

⚙️ 外部命令 (1)
審計者: claude 查看審計歷史 →

品質評分

38
架構
100
可維護性
85
內容
30
社群
100
安全
91
規範符合性

你能建構什麼

快速分支状态检查

获取当前分支、未提交更改和同步状态的摘要

分支创建流程

按命名规范创建功能分支并进行错误处理

Git 学习辅助

通过错误解决步骤的指导学习 git 分支操作

試試這些提示

检查当前分支
检查当前分支状态。告诉我当前分支、任何未提交的更改,以及它与主分支的最新同步情况。
创建功能分支
从主分支创建一个名为 feature/my-feature-name 的新分支。首先确保主分支是最新的。
处理分支错误
我在尝试处理分支时遇到错误。请帮我解决。错误是:[describe error]
解决冲突
帮我解决当前分支中的合并冲突。先告诉我哪些文件有冲突,然后引导我完成解决。

最佳實務

  • 在创建或更新分支之前始终从远程拉取最新内容
  • 切换分支前先暂存或提交未提交的更改
  • 确认分支命名规范符合团队标准

避免

  • 使用带空格或特殊字符的名称创建分支
  • 未经团队批准对共享分支进行强制推送
  • 忽略合并冲突并将其保持未解决状态

常見問題

这个技能适用于 GitHub、GitLab 和 Bitbucket 吗?
是的,它适用于任何 Git 托管服务,因为它使用标准的 Git 命令。
如果我尝试创建一个已经存在的分支会发生什么?
该技能会检测冲突并进行报告,建议替代方案或确认使用现有分支。
我可以用它配合 GitHub CLI 来创建拉取请求吗?
该技能使用 Git 命令。GitHub CLI 集成需要单独的技能。
这个技能会不会影响我的仓库数据安全?
可以,该技能只读取仓库状态并创建分支。不进行删除或强制操作。
如果我遇到复杂的合并冲突怎么办?
该技能为简单冲突提供分步指导,并在复杂冲突时请求指导。
这和 Git 别名有什么不同?
该技能提供智能错误处理和指导,这是静态别名无法匹配的。

開發者詳情

檔案結構

📄 SKILL.md