Project Session Manager
Yeachan-Heo/oh-my-claudecode
Creates isolated git worktrees, with optional tmux sessions, for PR reviews, issue fixes and feature work across projects and repositories.
Sets up an isolated workspace before feature work or plan execution, preferring native worktree tools and falling back to git worktree, with instructions in Chinese.
SKILL.md written in Chinese; this summary is our English description.
$ npx skills add jnMetaCode/superpowers-zh --skill using-git-worktrees -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install jnMetaCode/superpowers-zh using-git-worktrees --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/jnMetaCode/superpowers-zh.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/using-git-worktrees .claude/skills/using-git-worktrees && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "using-git-worktrees" agent skill from https://github.com/jnMetaCode/superpowers-zh/tree/main/skills/using-git-worktrees into .claude/skills/using-git-worktrees/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "using-git-worktrees", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/jnMetaCode/superpowers-zh/tree/main/skills/using-git-worktreesType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add jnMetaCode/superpowers-zh --skill using-git-worktrees -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install jnMetaCode/superpowers-zh using-git-worktrees --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/jnMetaCode/superpowers-zh.git skills-src && mkdir -p .agents/skills && cp -r skills-src/skills/using-git-worktrees .agents/skills/using-git-worktrees && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "using-git-worktrees" agent skill from https://github.com/jnMetaCode/superpowers-zh/tree/main/skills/using-git-worktrees into .agents/skills/using-git-worktrees/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "using-git-worktrees", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add jnMetaCode/superpowers-zh --skill using-git-worktrees -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install jnMetaCode/superpowers-zh using-git-worktrees --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/jnMetaCode/superpowers-zh.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/skills/using-git-worktrees .cursor/skills/using-git-worktrees && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "using-git-worktrees" agent skill from https://github.com/jnMetaCode/superpowers-zh/tree/main/skills/using-git-worktrees into .cursor/skills/using-git-worktrees/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "using-git-worktrees", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/jnMetaCode/superpowers-zh.git --path skills/using-git-worktrees--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add jnMetaCode/superpowers-zh --skill using-git-worktrees -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install jnMetaCode/superpowers-zh using-git-worktrees --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/jnMetaCode/superpowers-zh.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/skills/using-git-worktrees .gemini/skills/using-git-worktrees && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "using-git-worktrees" agent skill from https://github.com/jnMetaCode/superpowers-zh/tree/main/skills/using-git-worktrees into .gemini/skills/using-git-worktrees/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "using-git-worktrees", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install jnMetaCode/superpowers-zh using-git-worktreesInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add jnMetaCode/superpowers-zh --skill using-git-worktrees -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/jnMetaCode/superpowers-zh.git skills-src && mkdir -p .github/skills && cp -r skills-src/skills/using-git-worktrees .github/skills/using-git-worktrees && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "using-git-worktrees" agent skill from https://github.com/jnMetaCode/superpowers-zh/tree/main/skills/using-git-worktrees into .github/skills/using-git-worktrees/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "using-git-worktrees", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add jnMetaCode/superpowers-zh --skill using-git-worktrees -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install jnMetaCode/superpowers-zh using-git-worktrees --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/jnMetaCode/superpowers-zh.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/skills/using-git-worktrees .opencode/skills/using-git-worktrees && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "using-git-worktrees" agent skill from https://github.com/jnMetaCode/superpowers-zh/tree/main/skills/using-git-worktrees into .opencode/skills/using-git-worktrees/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "using-git-worktrees", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
using-git-worktreesSets up an isolated workspace before feature work or plan execution, preferring native worktree tools and falling back to git worktree, with instructions in Chinese.
A Chinese translation of a worktree setup workflow. It first detects whether you are already in a linked worktree by comparing the git dir and the common git dir, with a guard so that submodules are not mistaken for worktrees, and it does not create another worktree if you are. In a normal checkout it asks for consent unless you have already stated a preference.
Creation tries the platform's native worktree tool first, such as EnterWorktree, WorktreeCreate, a /worktree command or a --worktree flag, and only then falls back to git worktree add, to avoid phantom state the harness cannot manage. The fallback chooses .worktrees or worktrees, defaulting to .worktrees, and verifies that the directory is ignored by git before creating anything, adding it to .gitignore if not. If a sandbox refuses creation, the agent works in place. After that it runs project setup such as npm install and checks that the baseline tests pass.
3 steps, taken from the first numbered list in SKILL.md.
Read from SKILL.md and the folder at commit fe34019. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
Shell commands in SKILL.md call:
gitnpmFrom the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md. Its commands use git and npm, which can reach the network depending on how they are called.
From URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Git Worktree Isolation loads about 982 tokens when it runs. Until then it costs about 22 tokens; SKILL.md has 245 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from jnMetaCode/superpowers-zh at commit fe34019, republished under its MIT licence (© jnMetaCode). 245 words, ~982 tokens.
.claude/skills/using-git-worktrees/SKILL.md (or your agent's skills folder).确保工作发生在隔离的工作区中。优先使用你的平台的原生 worktree 工具。仅在没有原生工具可用时,再回退到手动 git worktree。
核心原则: 先检测现有隔离。然后用原生工具。再回退到 git。绝不与 harness 对抗。
开始时宣布: "我正在使用 using-git-worktrees 技能来建立一个隔离的工作区。"
创建任何东西之前,先检查你是否已经在一个隔离的工作区里。
GIT_DIR=$(cd "$(git rev-parse --git-dir)" 2>/dev/null && pwd -P)
GIT_COMMON=$(cd "$(git rev-parse --git-common-dir)" 2>/dev/null && pwd -P)
BRANCH=$(git branch --show-current)Submodule 守卫: 在 git submodule 内 GIT_DIR != GIT_COMMON 也为真。在判定"已经在 worktree 内"之前,先确认你不在 submodule 里:
# 如果这条命令返回路径,说明你在 submodule 里,不是 worktree —— 按普通仓库处理
git rev-parse --show-superproject-working-tree 2>/dev/null如果 GIT_DIR != GIT_COMMON(且不是 submodule): 你已经在一个 linked worktree 内。跳到步骤 2(项目设置)。不要再创建一个 worktree。
按分支状态报告:
<path>,分支 <name>。"<path>(分离 HEAD,由外部管理)。完成时需要创建分支。"如果 GIT_DIR == GIT_COMMON(或在 submodule 内): 你在一个普通的仓库检出里。
用户是否已经在你的 instructions 里表明过 worktree 偏好?如果没有,创建 worktree 之前先征求同意:
"你希望我搭一个隔离的 worktree 吗?它能保护你当前分支不被改动。"
如果用户已声明过偏好,直接遵循,不再询问。如果用户拒绝同意,原地工作并跳到步骤 2。
你有两种机制。按这个顺序尝试。
用户已经请求隔离工作区(步骤 0 已获同意)。你是否已经有创建 worktree 的方法?可能是名为 EnterWorktree、WorktreeCreate 的工具、/worktree 命令,或 --worktree 标志。如果有,用它,然后跳到步骤 2。
原生工具自动处理目录放置、分支创建和清理。在你已经有原生工具的情况下使用 git worktree add,会创建你的 harness 看不到也无法管理的"幻影状态"。
只有在没有原生 worktree 工具可用时,才进入步骤 1b。
只在步骤 1a 不适用时使用 —— 你没有可用的原生 worktree 工具。手动用 git 创建 worktree。
按以下优先级。明确的用户偏好始终优先于观察到的文件系统状态。
检查你的 instructions 里是否声明过 worktree 目录偏好。 如果用户已指定,不再询问直接用。
检查是否存在项目本地的 worktree 目录:
ls -d .worktrees 2>/dev/null # 首选(隐藏目录)
ls -d worktrees 2>/dev/null # 备选找到就用。如果两者都存在,.worktrees 优先。
如果没有其他可参考的信息,默认用项目根目录下的 .worktrees/。
创建 worktree 前必须验证目录已被忽略:
git check-ignore -q .worktrees 2>/dev/null || git check-ignore -q worktrees 2>/dev/null如果未被忽略: 添加到 .gitignore,提交该改动,然后继续。
为什么关键: 防止 worktree 内容被意外提交到仓库。
# 根据选定位置确定路径
path="$LOCATION/$BRANCH_NAME"
git worktree add "$path" -b "$BRANCH_NAME"
cd "$path"沙盒回退: 如果 git worktree add 因权限错误(沙盒拒绝)失败,告诉用户沙盒阻止了 worktree 创建,你将在当前目录原地工作。然后原地运行 setup 和基线测试。
自动检测并运行相应的设置命令:
# Node.js
if [ -f package.json ]; then npm install; fi
# Rust
if [ -f Cargo.toml ]; then cargo build; fi
# Python
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
if [ -f pyproject.toml ]; then poetry install; fi
# Go
if [ -f go.mod ]; then go mod download; fi运行测试确保工作区初始状态干净:
# 使用项目对应的命令
npm test / cargo test / pytest / go test ./...如果测试失败: 报告失败,询问是继续还是排查。
如果测试通过: 报告就绪。
工作树已就绪:<full-path>
测试通过(<N> 个测试,0 个失败)
准备实现 <feature-name>| 情况 | 操作 |
|---|---|
| 已在 linked worktree 内 | 跳过创建(步骤 0) |
| 在 submodule 内 | 按普通仓库处理(步骤 0 守卫) |
| 有原生 worktree 工具 | 用它(步骤 1a) |
| 没有原生工具 | git worktree 回退(步骤 1b) |
.worktrees/ 存在 | 用它(验证已忽略) |
worktrees/ 存在 | 用它(验证已忽略) |
| 两者都存在 | 用 .worktrees/ |
| 都不存在 | 检查 instructions 文件,再默认 .worktrees/ |
| 目录未被忽略 | 添加到 .gitignore + 提交 |
| 创建时权限错误 | 沙盒回退,原地工作 |
| 基线测试失败 | 报告失败 + 询问 |
| 无 package.json/Cargo.toml | 跳过依赖安装 |
| 借口 | 现实 |
|---|---|
| "我显然不在 worktree 里,不用检查" | 跑步骤 0。宿主环境创建的隔离和 submodule 都能骗过肉眼;只有检测命令能定论。 |
"git worktree add 比去找原生工具快" | 原生工具(如 EnterWorktree)掌管位置、分支和清理。绕过它是第一大错误 —— 会造出你的宿主环境看不见也管不了的幽灵状态。 |
| "这个 worktree 目录肯定已经被忽略了" | 跑 git check-ignore。一个没被忽略的 worktree 目录会把整棵树提交进仓库。 |
| "目录名随便取都行" | 明确指示 > 已存在的项目内目录 > .worktrees/ 默认值。 |
| "工作区是全新的,基线测试可以先放放" | 基线不干净会让之后每一次失败都含义不明。现在就跑测试;越过失败继续是你人类伙伴的决定。 |
© jnMetaCode, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
Just SKILL.md in skills/using-git-worktrees of jnMetaCode/superpowers-zh.
Open the folder on GitHubat commit fe34019
We found 1 copy of this SKILL.md (exact, near-identical or edited) in other folders, from 1 other GitHub owner. This page covers the copy in jnMetaCode/superpowers-zh, which our catalogue first saw on October 7, 2026.
Git Worktree Isolation next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Git Worktree Isolation this skilljnMetaCode/superpowers-zh | 8.3k | 1 repos | ~982 | Automated safety check: Pass | MIT | |
| Project Session ManagerYeachan-Heo/oh-my-claudecode | 40k | — | ~4k | Automated safety check: Pass | MIT | |
| Multi Agent Orchestrationcat-xierluo/legal-skills | 713 | — | ~6.6k | Automated safety check: Pass | MIT | |
| Polyphonyalinaqi/maggy | 707 | — | ~980 | Automated safety check: Pass | MIT | |
| Finishing a Development Branchobra/superpowers | 296k | 5 repos | ~1.9k | Automated safety check: Pass | MIT | |
| Git Worktree Cleanuplobehub/lobehub | 83k | — | ~2.8k | Automated safety check: Pass | Custom licence |
Yeachan-Heo/oh-my-claudecode
Creates isolated git worktrees, with optional tmux sessions, for PR reviews, issue fixes and feature work across projects and repositories.
cat-xierluo/legal-skills
编排两个以上边界独立的本地 worker,使用 Orca Run/Task/Dispatch、独立 worktree/session 或 tmux 回退,由 PM 负责拆解、派发、巡检、429 停滞恢复、独立验收、PR 收口与临时资源清理;也用于用户明确要求“并行推进”“多个 worker”“PM 总控”“Wave Autopilot”或防止 PM…
alinaqi/maggy
Multi-agent orchestration with container-isolated workspaces — each agent session runs in its own Docker container with independent git branches
obra/superpowers
Walks the last step of a branch: confirm tests pass, detect the git environment, ask how to integrate, carry out your choice and clean up the worktree.
lobehub/lobehub
Audits stale Git worktrees and branches with a bundled script, classifies each one, and deletes only after you approve the exact candidates.
kbwo/ccmanager
Set up, review, or repair a CCManager config — .ccmanager.json at a git repository root, or the global ~/.config/ccmanager/config.json.
jnMetaCode/superpowers-zh
Turns a rough idea into an approved design before any code is written, sorting the request into spike, bounded or architectural and enforcing an approval gate.
jnMetaCode/superpowers-zh
Executes a written implementation plan task by task in the current session, with a progress ledger, test-first gates and one fresh-context review at the end.
jnMetaCode/superpowers-zh
Runs agency-orchestrator YAML workflows inside the current agent session, with the session's own model playing each role in turn and no API key needed.
jnMetaCode/superpowers-zh
Gives Chinese-language templates and priority labels for code review feedback, plus guidance on bilingual comments, commit messages and common team anti-patterns.
jnMetaCode/superpowers-zh
Reference for Chinese-language git commits and changelogs: Conventional Commits adapted for Chinese teams, with templates, breaking-change notes and issue links for several platforms.
jnMetaCode/superpowers-zh
Reference rules for typesetting Chinese technical documents: spacing around English and digits, punctuation, term handling, bilingual API docs and README layout.
Works with
Categories
Sets up an isolated workspace before feature work or plan execution, preferring native worktree tools and falling back to git worktree, with instructions in Chinese. A Chinese translation of a worktree setup workflow. It first detects whether you are already in a linked worktree by comparing the git dir and the common git dir, with a guard so that submodules are not mistaken for worktrees, and it does not create another worktree if you are.
Git Worktree Isolation fits situations like: starting feature work that should stay isolated from the current branch; before executing an implementation plan; checking whether you are already inside a worktree.
Run `npx skills add jnMetaCode/superpowers-zh --skill using-git-worktrees -a claude-code`. Or copy the skill folder (skills/using-git-worktrees in jnMetaCode/superpowers-zh) into .claude/skills/using-git-worktrees in your project. Claude Code loads it when a task matches its description.
Run `npx skills add jnMetaCode/superpowers-zh --skill using-git-worktrees -a codex`. Or copy the skill folder (skills/using-git-worktrees in jnMetaCode/superpowers-zh) into .agents/skills/using-git-worktrees in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add jnMetaCode/superpowers-zh --skill using-git-worktrees -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/using-git-worktrees, .gemini/skills/using-git-worktrees, .github/skills/using-git-worktrees and .opencode/skills/using-git-worktrees in your project.
Going by SKILL.md and its folder, Git Worktree Isolation needs the command-line tools its instructions call (git and npm). Our summary lists: Git.
SKILL.md contains no URLs. Its commands use git and npm, which can reach the network depending on how they are called. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
Git Worktree Isolation is published under the MIT licence (declared in SKILL.md). It allows redistribution, so the full SKILL.md is shown on this page.
About 982 tokens (SKILL.md is roughly 3.9k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with Git Worktree Isolation: Project Session Manager (Yeachan-Heo/oh-my-claudecode, 40k stars), Multi Agent Orchestration (cat-xierluo/legal-skills, 713 stars), Polyphony (alinaqi/maggy, 707 stars) and Finishing a Development Branch (obra/superpowers, 296k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
jnMetaCode (a GitHub user) maintains it in jnMetaCode/superpowers-zh, which has 8,265 GitHub stars. The repository holds 21 skills in this directory. The repository was last updated on October 4, 2026.
Source: jnMetaCode/superpowers-zh on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.