using-git-worktrees

Create isolated git worktrees for feature development with safety verification.

223|23|Updated Dec 19, 2025
One-click install
npx skills add https://github.com/ReinaMacCredy/maestro --skill using-git-worktrees-reinamaccredy
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: using-git-worktrees
Source: https://github.com/ReinaMacCredy/maestro/tree/main/skills/using-git-worktrees
Command: npx skills add https://github.com/ReinaMacCredy/maestro --skill using-git-worktrees-reinamaccredy

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill helps you create isolated git worktrees for starting feature work that should run independently from your current workspace. It ensures safe directory selection and verification to prevent accidentally committing worktree contents to the repository.

Core Features & Use Cases

  • Isolated workspaces: Create and switch to a dedicated worktree on a new branch without altering your main workspace.
  • Smart directory selection: Automatically choose between project-local (.worktrees) or global locations.
  • Safety verification: Check .gitignore and enforce updates to avoid leaking worktree contents.
  • Use Case: When starting a feature, generate a worktree, install dependencies, run tests, and keep the main branch clean.

Quick Start

Create an isolated worktree for a new feature branch and verify the baseline by running tests. If you want to use a global location, ask for permission to switch.

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 isolated git worktrees for feature development?

Git worktrees let you create separate working directories for different branches without switching your main workspace. This Skill automates worktree creation, applies safety checks to your .gitignore, and runs baseline tests to confirm the isolated environment is ready for feature work.

What's the difference between project-local and global git worktrees?

Project-local worktrees store in .worktrees within your repository and are excluded via .gitignore to prevent accidental commits. Global worktrees live outside the repo. This Skill prioritizes project-local placement by default and verifies .gitignore configuration for safety.

Can I use git worktrees to keep my main branch clean while developing features?

Yes. Worktrees isolate feature development on separate branches so your main workspace remains untouched. This Skill creates the worktree, optionally installs dependencies based on detected tooling, runs tests, and reports readiness without modifying your primary branch.

How do I switch to a global worktree location instead of project-local?

This Skill defaults to project-local .worktrees directories for safety. It can prompt you to request permission for global locations when needed, giving you control over where isolated worktrees are created.

Why should I verify .gitignore before creating a worktree?

Without proper .gitignore configuration, worktree contents can accidentally be committed to the repository. This Skill enforces .gitignore safety verification for project-local worktrees to prevent leaking isolated development files into version control.

Does this Skill automatically set up dependencies in a new worktree?

Yes. This Skill detects your project's tooling and automatically runs project setup—like dependency installation—in the new worktree, then validates readiness with baseline tests before reporting the environment is ready.