lazygit
lazygit copied to clipboard
ESC does not quit the application
Describe the bug ESC does not quit the application
To Reproduce Open lazy git and press ESC.
Expected behavior The application should be closed like in version 0.25.1
Desktop: OS: Windows 10.0.19042 Terminal: WindowsTerminal 1.6.10571.0 Powershell: 7.1.3 Lazygit Version 0.27.4
Found right now, I cant navigate to the next tab with ] or open the tree view with `
I have found the memo :man_facepalming: The ESC feature was replaced with q or CTRL+c.
I need to get better at communicating changes haha. I think I need a 'click here to see what's changed' popup when starting lazygit on a new version, which links to a nicely formatted release notes page on github
Some more info to the comment here. Since the new UI framework, I can't use any key combination anymore.
For example:
in order to enter ] I have to press ctrl+alt+9 since I'm using GER keyboard layout. In the version, 25.xx was everything just fine.
Since version 27 is not working anymore.
The easiest workaround is the config.yml keybinding section.
Now to the problem. Since version 28 we have a very nice Command Log tab, which can be focused with @ so I have to press ctrl+alt+q (I know, horrible 😄 ). AFAIK there is no custom binding yet to customize this command. Therefore I'm not able to select this tab without switching my keyboard layout.
@MiroslavMikus that's annoying.
How have you modified your config.yml to make the keybindings work again?
About the command log keybinding i think you need this config to modify it:
keybinding:
universal:
extrasMenu: '@'
This keybinding wan't mentioned in the docs but now it does
Hey @mjarkk , thanks for the memo :) works like a charm.
@jesseduffield If is the disability to use a combined shortcut like ctrl+alt+q to call functions behind @ known and accepted behavior, we can close this issue :)
Well you mention that from v25 to v27 you need to press extra keys for some keyboard shortcuts and as there are a lot of users around the world with messed up keyboard layouts we might want to look into this if we can fix it.
Is it possible to define a custom key binding that makes pressing
@mvolkmann yes, check the docs to see how to override the keybinding.universal.quit mapping.
I tried this in my ~/.config/lazygit/config.yml file, but pressing the esc key doesn't quit. Do you see what I'm doing wrong?
git:
keybinding:
universal:
quit-alt1: "<esc>"
paging:
colorArg: always
pager: delta --dark --paging=never --side-by-side
useConfig: true
quitOnTopLevelReturn: true
gui:
showIcons:
true
Side note, my attempt to configure side-by-side diffs is also not working.
I tried this in my
~/.config/lazygit/config.ymlfile, but pressing theesckey doesn't quit. Do you see what I'm doing wrong?git: keybinding: universal: quit-alt1: "<esc>" paging: colorArg: always pager: delta --dark --paging=never --side-by-side useConfig: true quitOnTopLevelReturn: true gui: showIcons: true
If you take a look at the Config.md in the docs, the keybinding is not under git, but at the top-level (this excerpt is from said file):
keybinding:
universal:
quit: 'q'
quit-alt1: '<c-c>' # alternative/alias of quit
Side note, my attempt to configure side-by-side diffs is also not working.
I haven't used a custom pager, but I encourage you to come and ask on discord, surely someone will be of help.
The configuration you shared works for me to enable quitting by pressing ctrl-c. But if I change "c-c" to "esc", pressing the escape key does not quit. I wonder if it's not possible to configure that to work.
quitOnTopLevelReturn is a top-level config. It should not be nested inside git config. That is why it is not triggering for you.