using-git-worktrees

Create isolated git worktrees with safety checks and automatic project setup.

1|Updated Jan 14, 2026
One-click install
npx skills add https://github.com/DecentralizedGeo/stac-manager --skill using-git-worktrees-decentralizedgeo
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: using-git-worktrees
Source: https://github.com/DecentralizedGeo/stac-manager/tree/main/.github/skills/using-git-worktrees
Command: npx skills add https://github.com/DecentralizedGeo/stac-manager --skill using-git-worktrees-decentralizedgeo

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Git worktrees create isolated workspaces sharing the same repository, allowing work on multiple branches simultaneously without switching.

Core Features & Use Cases

  • Directory selection precedence: prefer existing .worktrees, then worktrees, else consult CLAUDE.md, or prompt for a location.
  • Safety verifications: ensures worktrees are ignored by git before creation and follow cleanup rules.
  • Automatic project setup: detects project type (Node.js, Rust, Python, Go) and prepares the environment.

Quick Start

Set up an isolated git worktree for the current project, using the preferred location and ensuring the worktree is ignored.

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

To create an isolated git worktree, the Skill automates directory discovery by preferring existing .worktrees or worktrees folders, consulting CLAUDE.md, or prompting for a location. It verifies gitignore rules and sets up the environment for Node.js, Rust, Python, or Go projects.

What is the best way to work on multiple git branches simultaneously without switching?

Git worktrees provide isolated workspaces sharing the same repository, allowing simultaneous branch work without switching. This Skill automates worktree creation with safety checks to ensure the new workspaces are properly ignored and do not disturb the main working tree.

Does git worktree isolation work with Python and Rust project setups?

Yes, git worktree isolation supports Python, Rust, Node.js, and Go projects. The Skill automatically detects the project type during worktree creation and prepares the isolated environment with the appropriate setup commands for the detected toolchain.

Why does my git worktree need to be ignored by gitignore rules?

Git worktree directories must be ignored by gitignore rules to prevent the main repository from tracking the isolated workspaces. The Skill performs safety verifications to ensure worktrees are properly ignored before creation, avoiding repository pollution and conflicts.

Can I use a global location instead of a project-local directory for git worktrees?

Yes, you can use a global location for git worktrees. The Skill applies a directory selection precedence that prefers existing project-local .worktrees or worktrees directories, but will consult CLAUDE.md preferences or prompt for a dynamic path if local directories are unavailable.

When should I use git worktrees instead of standard git branching?

Use git worktrees when you need to develop features in isolation without disturbing the main working tree or when running multiple branches simultaneously. The Skill automates this isolation with safety checks, making it ideal for parallel feature work across shared repositories.