一键导入
git-branch
Creates a new branch in a git repository with an optional starting point.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Creates a new branch in a git repository with an optional starting point.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Checks whether a given path exists in the filesystem, returning a boolean result for both files and directories.
Copies a file from a source path to a destination path. The source file remains unchanged after the operation.
Removes a file or empty directory at the specified path. Recursive deletion and trash/recycle-bin moves are out of scope.
Replaces the first occurrence of old_string with new_string in a file.
Searches a directory tree recursively for files whose relative path matches a glob pattern, returning an array of absolute file paths.
Stages specified file paths or glob patterns for commit in a git repository.
| name | git_branch |
| version | 1.0.0 |
| author | clawthority |
| license | MIT-0 |
| description | Creates a new branch in a git repository with an optional starting point. |
| read_when | user asks to create a branch, make a new branch, or branch from a commit or ref |
| action_class | vcs.write |
You are the git_branch tool for Clawthority. You create a new branch in a git repository by running git branch <name> [<from>].
You accept a branch name (name) and an optional starting point (from) and create a new branch without switching to it. On success you return the branch name and a status message. If the branch already exists you raise a branch-already-exists error. If the starting point does not exist you raise a from-not-found error.
Invoke this tool when the user or agent wants to:
branch feature/my-feature)branch hotfix from v1.2.0)| Name | Type | Required | Description |
|---|---|---|---|
name | string | Yes | Name of the new branch to create. |
from | string | No | Optional starting point (branch name, tag, or commit hash). Defaults to HEAD. |
| Name | Type | Description |
|---|---|---|
name | string | The name of the branch that was created. |
message | string | Human-readable status message. |
{
"tool": "git_branch",
"params": {
"name": "feature/my-feature"
}
}
{
"tool": "git_branch",
"params": {
"name": "hotfix",
"from": "v1.2.0"
}
}
| Error Code | Cause |
|---|---|
branch-already-exists | A branch with the specified name already exists in the repository. |
from-not-found | The specified starting point does not exist. |
git-error | git branch exited with a non-zero status for another reason. |
When code is branch-already-exists, the user must choose a different branch name or delete the existing branch first.
git_checkout after creation)This tool is classified as vcs.write — a medium-risk operation that modifies the repository's ref namespace. It is subject to per_request HITL gating when HITL policies are active.