jesseduffield / jesseduffield/lazygit
Allow copyToClipboard (<c-o>) to work in the Command Log panel
- Dominant language
- Go
- Stars
- 82.4k
- Forks
- 3k
- Avg merge
- 2d 18h
- Merged PRs (30d)
- 19
Description
### Is your feature request related to a problem? Please describe.
When a git command fails or prints something useful (e.g. a pre-push hook dumping errors), the output lands in the Command Log panel — but there's no way to copy it. The only option today is to do a terminal-native selection, which doesn't work conveniently for multi-page output in the panel. This was previously raised in discussion #4875.
### Describe the solution you'd like
Extend the existing `copyToClipboard` command — added for confirmation/error popups in #4810 (default ``, shipped in v0.55.0) — so it also works when the **Command Log panel** is focused, copying the panel's contents (or the selected region) to the clipboard.
### Describe alternatives you've considered
- Terminal-native selection (hold Shift): terminal-dependent, awkward for multi-page log output.
- `lazygit --debug` + `--logs`: captures executed commands but is noisy and isn't the panel's rendered content.
- Custom commands: these operate on git context (selected commit/file/branch), not lazygit's internal Command Log buffer, so they can't read it.
### Additional context
Popups already support `` via #4810, so there's precedent and likely a reusable code path. Related: discussion #4875.
Contributor guide
Assessment
This issue has not been assessed yet.