Manage parallel Gemini CLI instances
Project description
🔷 Gemini-Worktree
Run multiple Gemini Code instances in parallel without stepping on each other. This CLI creates isolated git worktrees for each Gemini session, so you can work on different features simultaneously while keeping your main branch clean.
This is a fork of claude-wt that works with Gemini instead of Claude. Inspired by Jeremiah Lowin.
🚀 Quick Start
Jump right in without installing anything:
uvx gemini-wt new
That's it. You're now working in a clean branch where Gemini can't mess up your pristine codebase.
Installation Options
If you prefer global installation:
uv tool install gemini-wt
🎯 Commands
✨ Start Fresh: new
Spin up a new isolated Gemini session:
uvx gemini-wt new
Behind the scenes: creates a timestamp branch, sets up a worktree in .gemini/worktrees/, and launches Gemini in the isolated environment.
Want a memorable branch name? Use --name:
uvx gemini-wt new --name parser-fix
Need to branch from a specific source? Use --branch:
uvx gemini-wt new --branch main --name hotfix-123
🔄 Pick Up Where You Left Off: resume
Gemini sessions are like good TV shows—you want to continue watching:
uvx gemini-wt resume 20241201-143022 (your the branch name)
The session ID is shown when you create it.
📋 See What's Running: list
See all your active worktrees:
uvx gemini-wt list
Shows each session with its health status.
🧹 Clean Up: clean
Remove a specific session when you're done:
uvx gemini-wt clean 20241201-143022
Or clean everything:
uvx gemini-wt clean --all # The Marie Kondo approach
🔧 How It Works
Think of it like having multiple parallel universes for your code:
- Branch Creation → Each session gets its own branch (
gemini-{timestamp}or your custom name) - Worktree Setup → Creates a separate directory in
.gemini/worktrees/so files don't conflict - Gemini Launch → Starts Gemini in the isolated environment with full repo access
- Session Management → Resume, list, and clean up sessions effortlessly
🎁 Why You'll Love This
- Fear-Free Experimentation → Gemini can't break your main branch even if it tries
- Mental Clarity → No more "did I commit that test code?" anxiety
- Context Switching → Jump between different Gemini conversations effortlessly
- Easy Cleanup → One command to remove all experimental branches
- Clean History → Your main branch stays pristine for serious work
📋 What You Need
- Python 3.12+
- Git with worktree support (any recent version)
- Gemini CLI (installed and authenticated)
🛠️ Development
Uses uv for dependency management:
uv sync
uv run gemini-wt --help
Or test changes without installing:
uvx --from . gemini-wt --help
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file gemini_wt-0.1.2.tar.gz.
File metadata
- Download URL: gemini_wt-0.1.2.tar.gz
- Upload date:
- Size: 15.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: uv/0.8.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4a2959956e754ead8c052cc9d4d67380808298bb634d816e6878bc2801c3d8e9
|
|
| MD5 |
00ad8a8eef1ac217406b905ff32b40ab
|
|
| BLAKE2b-256 |
b5ca29da09f8ef6823cbd7e2e3b914dfa6698ff3ae8115b7a94fe4c373d80bf3
|
File details
Details for the file gemini_wt-0.1.2-py3-none-any.whl.
File metadata
- Download URL: gemini_wt-0.1.2-py3-none-any.whl
- Upload date:
- Size: 6.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: uv/0.8.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f13e1b07485b8db2d1237c5c012736e52d8278bcbd17ed49b46024589405566f
|
|
| MD5 |
ac29a98639150f54c48a0749a5b10273
|
|
| BLAKE2b-256 |
b9f46ebafbc72f8a86aa097577711ec6887d8f07107dae93af111ab2f5ac8e96
|