Kosho is a CLI tool that automates git worktree management, enabling developers to work on multiple branches concurrently. It simplifies complex workflows by creating and managing worktrees in dedicated directories, reducing context switching and improving productivity. Ideal for teams using Git for version control.
git clone https://github.com/carlsverre/kosho.gitKosho is a CLI tool that automates git worktree management, enabling developers to work on multiple branches concurrently. It simplifies complex workflows by creating and managing worktrees in dedicated directories, reducing context switching and improving productivity. Ideal for teams using Git for version control.
1. **Install kosho**: Run `pip install kosho` or use your package manager (e.g., `brew install kosho`). Ensure Git is installed and configured on your system. 2. **Navigate to your repository**: Use `cd [PROJECT_PATH]` to enter the root directory of your Git repository. 3. **Create a worktree**: Execute `kosho worktree add -b [BRANCH_NAME] [DIRECTORY_PATH]` to create a new worktree for a specific branch. Replace placeholders with your branch name (e.g., `feature/new-ui`) and directory path (e.g., `../worktrees/new-ui`). 4. **List worktrees**: Run `kosho worktree list` to view all active worktrees, their branches, commit statuses, and paths. Use this to track your progress and switch between tasks. 5. **Clean up**: To remove a worktree, use `kosho worktree remove [DIRECTORY_PATH]`. Ensure you’ve committed or stashed changes first to avoid data loss. **Tips:** - Use descriptive directory names (e.g., `../worktrees/feature-auth`) to quickly identify worktrees. - Regularly run `kosho worktree list` to monitor the status of all worktrees and avoid conflicts. - Combine kosho with Git hooks or CI/CD pipelines to automate worktree cleanup after merging branches.
No install command available. Check the GitHub repository for manual installation instructions.
git clone https://github.com/carlsverre/koshoCopy the install command above and run it in your terminal.
Launch Claude Code, Cursor, or your preferred AI coding agent.
Use the prompt template or examples below to test the skill.
Adapt the skill to your specific use case and workflow.
Use kosho to automate git worktree management for the [PROJECT_NAME] repository. Create a new worktree for the [BRANCH_NAME] branch in the [DIRECTORY_PATH] directory. Ensure the worktree is clean and up-to-date with the latest changes. List all existing worktrees and their statuses.
```bash $ kosho worktree add -b feature/login-flow ../worktrees/login-flow Created worktree '../worktrees/login-flow' for branch 'feature/login-flow' at commit 'a1b2c3d'. $ kosho worktree list Worktree Path Branch Commit Status -------------------------------------------------------------- ./.git/worktrees/main main a1b2c3d clean ../worktrees/login-flow feature/login-flow a1b2c3d clean ../worktrees/bugfix/header bugfix/header d4e5f6a dirty ``` **Explanation:** The command `kosho worktree add -b feature/login-flow ../worktrees/login-flow` created a new worktree in `../worktrees/login-flow` for the `feature/login-flow` branch, checked out at the latest commit (`a1b2c3d`). The `kosho worktree list` command then displayed all active worktrees, showing their paths, associated branches, commit hashes, and statuses. The `bugfix/header` worktree is marked as 'dirty' because it has uncommitted changes. This setup allows you to work on the login flow feature alongside the main branch without switching contexts, reducing the cognitive load of juggling multiple branches in the same directory.
Modern microfinance solutions
IronCalc is a spreadsheet engine and ecosystem
ITIL-aligned IT service management platform
Customer feedback management made simple
Enterprise workflow automation and service management platform
Automate your spreadsheet tasks with AI power
Take a free 3-minute scan and get personalized AI skill recommendations.
Take free scan