attach / detach
gwt attach
Attach to a Zellij session. Creates the session if it doesn’t exist, then reconnects.
gwt attach [<branch>] [--all] [--session <name>]
Options
| Option | Description | Default |
|---|---|---|
<branch> | Create tab for this branch (error if branch/worktree doesn’t exist) | — |
--all | Create missing tabs for all worktrees | false |
--session, -s | Session name | gwt (or session.name from config) |
Behavior
gwt attach— reconnects to the session; no tab changesgwt attach <branch>— reconnects and creates a tab for the given branch if missing; errors if the branch or worktree doesn’t existgwt attach --all— reconnects and creates missing tabs for all worktrees
Also available as
gwt session attach [<branch>] [--all] [--session <name>]
gwt detach
Remove workspace tabs from a session.
gwt detach [<branch>] [--all] [--session <name>]
Options
| Option | Description | Default |
|---|---|---|
<branch> | Close the tab for this branch | — |
--all | Close all workspace tabs for this repo | false |
--session, -s | Session name | gwt (or session.name from config) |
Behavior
gwt detach— closes the current workspace tab (detected via CWD)gwt detach <branch>— closes the tab for the specified branchgwt detach --all— closes all workspace tabs for this repo- The session is automatically killed when no tabs remain
Also available as
gwt session detach [<branch>] [--all] [--session <name>]