Agent Skills: Git Worktrees

>

UncategorizedID: liuchengxu/dotfiles/git-worktrees

Install this agent skill to your local

pnpm dlx add-skill https://github.com/liuchengxu/dotfiles/tree/HEAD/agents/skills/git-worktrees

Skill Files

Browse the full folder contents for git-worktrees.

Download Skill

Loading file tree…

agents/skills/git-worktrees/SKILL.md

Skill Metadata

Name
git-worktrees
Description
>

Git Worktrees

Location

Worktrees live inside the repo:

git worktree add .claude/worktrees/<branch-name> -b <branch-name>

Sibling directories such as ../repo-wt/ are not used.

Pushing

Name the branch explicitly:

git push origin <branch-name>

A bare git push targets the main repo's branch, not the worktree's.

The gh CLI

gh cannot operate inside a worktree — the .git there is a text pointer, not a directory. Pass --repo owner/repo to bypass local git discovery:

gh pr create --repo babylonlabs-io/vault-provers --head branch-name ...