用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
直接命令不会经过审查 Prompt;运行前请先检查来源。
npx skills add https://github.com/chmouel/lazyworktree --skill worktree-manager命令会保持在同一行。复制前请横向滚动并检查完整内容。
想先保存到本地?可下载 SkillsMP 当前能够提供的文件。
Analyze repository documentation for implementation drift, stale examples, missing coverage, spelling/clarity issues, and reorganization opportunities; produce a prioritized report with exact file references and proposed fixes.
Check documentation consistency across README, man page, and help screen
Check DESIGN.md synchronization with codebase architecture
基于 SOC 职业分类
正在显示 SKILL.md
| name | worktree-manager |
| description | Create, list, switch to, rename, delete, and manage notes for git worktrees using lazyworktree CLI |
Manage git worktrees for the current repository using the lazyworktree CLI.
!lazyworktree list --json
!pwd
!git branch --show-current
From the current branch (new feature work):
# Auto-generated name (branch-adjective-noun pattern)
lazyworktree create --silent
# With a specific name
lazyworktree create --silent my-feature-name
# Carry over uncommitted changes to the new worktree
lazyworktree create --silent --with-change my-feature-name
# From a specific branch
lazyworktree create --silent --from-branch main my-feature-name
From a GitHub/GitLab PR:
lazyworktree create --silent --from-pr 42
# Create a local branch from a PR without creating a worktree
lazyworktree create --silent --from-pr 42 --no-workspace
From a GitHub/GitLab issue:
lazyworktree create --silent --from-issue 123
# Optionally specify a base branch
lazyworktree create --silent --from-issue 123 --from-branch main
# Create a local branch from an issue without creating a worktree
lazyworktree create --silent --from-issue 123 --no-workspace
Auto-generate worktree name from branch:
lazyworktree create --silent --generate
Run a command after creation:
lazyworktree create --silent --from-branch main my-feature --exec "npm install"
All create commands print the created worktree path to stdout on success.
# JSON output (for parsing)
lazyworktree list --json
# Paths only (one per line)
lazyworktree list --pristine
# Show only the main branch worktree
lazyworktree list --main
# Human-readable table
lazyworktree list
Alias: lazyworktree ls is equivalent to lazyworktree list.
JSON fields: path, name, branch, is_main, dirty, ahead, behind, unpushed, last_active.
Use exec to run commands in a specific worktree without changing directory:
# By worktree name or path
lazyworktree exec -w my-feature-name "make build"
lazyworktree exec -w /path/to/worktree "make build"
# Auto-detect worktree from current directory (no -w needed)
cd /path/to/my-feature && lazyworktree exec "git status"
# Run any shell command
lazyworktree exec -w my-feature-name "go test ./..."
# Trigger a custom command key instead of a shell command
lazyworktree exec -w my-feature-name --key t
Note: --key and a command argument are mutually exclusive.
# Rename current worktree (auto-detected from cwd)
lazyworktree rename --silent new-name
# Rename a specific worktree
lazyworktree rename --silent my-feature-name new-name
# Show the note for the current worktree (auto-detected from cwd)
lazyworktree note show
# Show the note for a specific worktree
lazyworktree note show my-feature-name
# Edit a worktree note (opens editor)
lazyworktree note edit my-feature-name
# Set a note from a file (use '-' for stdin)
lazyworktree note edit my-feature-name --input notes.md
echo "my note" | lazyworktree note edit my-feature-name --input -
# Delete worktree and its branch (if names match)
lazyworktree delete --silent my-feature-name
# Delete worktree but keep the branch
lazyworktree delete --silent --no-branch my-feature-name
# Auto-detect worktree from cwd (positional arg is optional)
cd /path/to/worktree && lazyworktree delete --silent
When the user asks to create a worktree:
lazyworktree create --silent commandlazyworktree exec -w <name> for subsequent commandsWhen the user asks to switch to a worktree:
lazyworktree list --json to find available worktreeslazyworktree exec -w <name> "<command>"cd <path>When the user asks to list worktrees:
lazyworktree list --json and present the resultsWhen the user asks to rename a worktree:
lazyworktree list --json to identify the worktreelazyworktree rename --silent <old-name> <new-name>When the user asks to view or edit worktree notes:
lazyworktree note show <name> (omit name to use cwd)echo "content" | lazyworktree note edit <name> --input -lazyworktree note edit <name> --input path/to/fileWhen the user asks to delete a worktree:
lazyworktree list --json to show current worktreeslazyworktree delete --silent <name>--silent flag suppresses progress messages to stderr; stdout still contains the result pathexec -w to run commands in a worktree without changing your shell's working directoryexec -w for running commands there and inform the user of the path for manual cd