Zsh Worktrunk Plugin
August 27, 2026 ยท View on GitHub
This is a Zsh plugin inspired by the Oh My Zsh git plugin which provides aliases and a few useful functions for working with worktrunk.
Usage
To use this plugin, clone it into $ZSH_CUSTOM/plugins:
git clone https://git.guzek.uk/kguzek/zsh-worktrunk.git "$ZSH_CUSTOM/plugins/"
... and add zsh-worktrunk to the plugins array in your .zshrc file:
plugins=(... zsh-worktrunk)
Aliases
| Alias | Description | Command |
|---|---|---|
wtl | List worktrees | wt list |
wts | Switch worktree | wt switch |
wtsm | Switch to main worktree | wt switch $(wt_main_tree) |
wtsc | Create and switch to a new worktree | wt switch --create |
wth | Run a configured hook | wt hook |
wtc | Commit the current changes | wt step commit |
wtcp | Copy files ignored by git to this worktree | wt step copy-ignored |
wtd | Show the current worktree's diff | wt step diff |
wtr | Delete worktree | wt remove |
wtR | Delete worktree (force) | wt remove --force |
Functions
| Function | Description |
|---|---|
wt_main_tree | Output the path to the main worktree |
Copyright
License: MIT
Copyright (c) 2026 Konrad Guzek