Skip to main content

gji overview

gji is a Git worktree CLI for developers who switch between feature work, pull request review, and maintenance tasks all day.

It gives each branch its own directory, dependencies, and terminal context so you can move between tasks without the normal stash, checkout, reinstall loop.

Why it matters more now

AI-assisted development increases the number of parallel tasks around a single repository.

It is now normal to have:

  • your main feature branch open
  • a pull request you need to review right now
  • a scratch branch for trying an agent-generated idea
  • another worktree for validating a risky refactor or migration

That makes Git worktrees more important, because one shared checkout becomes the bottleneck.

gji makes that parallel style practical by turning worktrees into a fast, repeatable daily workflow instead of a low-level Git trick.

Why it exists

Without worktrees, “quickly check one thing” usually turns into this:

  1. Stash or commit local changes.
  2. Checkout another branch.
  3. Reinstall dependencies or rebuild generated files.
  4. Review or patch something.
  5. Switch back and recover your original state.

gji compresses that to a few commands and keeps each task isolated.

What it helps with

  • Start a new feature branch in its own worktree.
  • Open a pull request locally without disturbing current work.
  • Warp to an existing worktree across registered repos.
  • Create a new worktree in another repo from the same command entry point.
  • Jump between active worktrees instantly.
  • Keep branch-specific node_modules, generated files, and editor state separate.
  • Rebase or clean up worktrees without manual path juggling.

Where it fits best

gji is especially useful if you regularly do one or more of these:

  • review pull requests while another feature is already open locally
  • maintain several long-lived branches in the same repository
  • work in projects where reinstalling dependencies is slow enough to be annoying
  • use editor workspaces, bookmarks, or scripts that benefit from stable branch paths
  • keep multiple human and AI-assisted tasks open in parallel

Core workflow

gji new feature/payment-refactor
gji pr 1234
gji warp repo-a/main
gji go main
gji remove feature/payment-refactor

Worktrees are stored at a deterministic path:

../worktrees/<repo>/<branch>

That keeps shell aliases, editor bookmarks, and setup scripts predictable.

Next steps