lazygit icon indicating copy to clipboard operation
lazygit copied to clipboard

Enhance the functionality of the workspace

Open aiysya opened this issue 4 months ago • 1 comments

Enhance the functionality of the workspace

example: git worktree list git worktree add ..\deploy\test test git worktree add ..\deploy\test tes

Quickly switch to the workspace

aiysya avatar Jul 09 '26 01:07 aiysya

All of these are available in lazygit. Worktrees are shown in the Worktrees panel that you can get to by selecting the Files panel and pressing ]; it is now also possible to show them in their own dedicated side panel by using a config such as

gui:
  sidePanels:
    - [status]
    - [files, submodules]
    - [branches, remotes, tags]
    - [commits, reflog]
    - [worktrees]
    - [stash]

I find it useful to combine this with

gui:
  expandFocusedSidePanel: true
  shrinkSidePanelsToContent: true

to save some vertical space.

Adding a worktree and a branch at the same time is available by pressing w on a selected branch or commit, or by pressing n in the worktrees panel.

stefanhaller avatar Jul 10 '26 15:07 stefanhaller