using-git-worktrees

Creates isolated git worktrees with directory selection, ignore verification, and baseline test validation.

Updated Mar 31, 2026
One-click install
npx skills add https://github.com/SESELOVSKYDarian/Vase --skill using-git-worktrees-seselovskydarian
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: using-git-worktrees
Source: https://github.com/SESELOVSKYDarian/Vase/tree/main/.agents/skills/using-git-worktrees
Command: npx skills add https://github.com/SESELOVSKYDarian/Vase --skill using-git-worktrees-seselovskydarian

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Working on multiple branches simultaneously often requires stashing changes or cloning the repository again, which disrupts your current workspace. This Skill sets up isolated git worktrees so you can develop features in parallel without switching branches or polluting your main checkout. ## Core Features & Use Cases - Smart Directory Selection: Follows a priority order (existing .worktrees/ or worktrees/ directory, then CLAUDE.md preference, then asks the user) to pick a consistent worktree location. - Safety Verification: Checks with git check-ignore that project-local worktree directories are gitignored before creation, and fixes the .gitignore automatically if not. - Automated Setup and Baseline Validation: Auto-detects the project type (Node.js, Rust, Python, Go), installs dependencies, and runs the test suite to confirm a clean baseline before work begins. - Use Case: You are mid-review on one branch when a high-priority feature request arrives. Use this Skill to spin up an isolated worktree on a new branch, install dependencies, and verify tests pass, all without touching your current workspace. ## Quick Start Set up an isolated git worktree for my new feature branch and verify the project tests pass before I start implementing.

Frequently Asked Questions about using-git-worktrees

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create a git worktree for a new feature branch?

Run git worktree add with a target path and the -b flag to create a new branch, for example git worktree add .worktrees/auth -b feature/auth. This Skill automates path selection, branch creation, dependency installation, and baseline test verification.

Where should git worktrees be stored in a project?

Worktrees can live in a project-local directory like .worktrees/ or worktrees/, or in a global location outside the repository. This Skill checks existing directories first, then CLAUDE.md preferences, then asks the user before creating anything.

Why must the worktree directory be in .gitignore?

If a project-local worktree directory is not gitignored, its contents appear in git status and can be accidentally committed to the repository. The Skill runs git check-ignore before creation and adds the entry to .gitignore if missing.

What happens if tests fail in a new worktree?

Failing baseline tests mean pre-existing issues exist before any new work begins. The Skill reports the failures and asks whether to proceed or investigate, rather than continuing on a broken baseline.

Does git worktree setup work with Python or Rust projects?

Yes, the setup step auto-detects the project type from marker files. It runs npm install for package.json, cargo build for Cargo.toml, pip or poetry install for Python, and go mod download for go.mod.