ck:worktree

Manage git worktrees for feature isolation, health audits, and cleanup.

Updated Jun 14, 2026
One-click install
npx skills add https://github.com/duy-tung/claude-code-setup --skill ck-worktree-duy-tung
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: ck:worktree
Source: https://github.com/duy-tung/claude-code-setup/tree/main/claude/skills/worktree
Command: npx skills add https://github.com/duy-tung/claude-code-setup --skill ck-worktree-duy-tung

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve?

The ck:worktree skill helps manage isolated git worktrees, addressing the challenges of feature isolation, worktree health, and monorepo/submodule workflows.

Core Features & Use Cases

  • Create Worktrees: Quickly create isolated worktrees for parallel feature development or audits.
  • Inspect Worktree Health: Check the status of worktrees, including branch divergence and uncommitted changes.
  • Cleanup Stale Worktrees: Identify and remove stale worktree metadata for cleaner repository management.
  • Monorepo/Submodule Workflows: Facilitate efficient workflows for projects with multiple related components.
  • Use Case: When developing a feature in a large codebase, you can use this skill to create a separate worktree for the feature, allowing parallel development and easy integration back into the main branch.

Quick Start

To create a new worktree, use the command: create <feature>.

Frequently Asked Questions about ck:worktree

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

FAQPage Schema
How do I create a git worktree for feature development in a monorepo?

To create a git worktree for feature development in a monorepo, run `create <feature>` to automatically isolate the branch, initialize submodules, and set up parallel development without leaving your main working directory.

How do I clean up stale git worktree metadata in my repository?

Clean up stale git worktree metadata by identifying and removing orphaned directory references left behind after feature branches are deleted, ensuring cleaner repository management and preventing branch tracking conflicts.

Can I use git worktrees for parallel feature development with submodules?

Yes, git worktrees support parallel feature development with submodules by automatically initializing submodule dependencies for each isolated worktree, facilitating efficient workflows for projects with multiple related components.

What version of git do I need to use worktrees?

Git worktrees require git version 2.5 or newer, which introduced the core worktree functionality needed to create, inspect, and clean isolated working directories for parallel branch development.

When should I use git worktrees instead of branching in a single directory?

Use git worktrees instead of single-directory branching when working in large codebases or monorepos requiring parallel development, allowing you to develop features concurrently and integrate them back without switching branches constantly.