From 43a9dc48e01dcc773997df09411d20ed79c1b6bb Mon Sep 17 00:00:00 2001 From: Jesse Duffield Date: Tue, 6 Apr 2021 09:23:47 +1000 Subject: [PATCH] default to not quitting when hitting esc at the top level. I've been using this config option for years now so I don't think much of it, but newcomers are going to find it annoying that hitting escape gets you out of filtering/cherry-picking/patch-building mode, but also quits the app. So if you want to exit all the modes you're in, you need to take care not to press the key one too many times or the app will close. We'll see if anybody gets mad about this change, but I think it's reasonable. The only downside is that you won't be able to always quit by spamming the escape key. If you're in a prompt panel, you'll need to hit escape to exit that, and then 'q' at the top level. Or CTRL+C of course. --- docs/Config.md | 2 +- pkg/config/user_config.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/Config.md b/docs/Config.md index 7dd0a30d0..f8eeb496d 100644 --- a/docs/Config.md +++ b/docs/Config.md @@ -61,7 +61,7 @@ Default path for the config file: reporting: 'undetermined' # one of: 'on' | 'off' | 'undetermined' confirmOnQuit: false # determines whether hitting 'esc' will quit the application when there is nothing to cancel/close - quitOnTopLevelReturn: true + quitOnTopLevelReturn: false disableStartupPopups: false notARepository: 'prompt' # one of: 'prompt' | 'create' | 'skip' keybinding: diff --git a/pkg/config/user_config.go b/pkg/config/user_config.go index b9221c01b..377ed05c0 100644 --- a/pkg/config/user_config.go +++ b/pkg/config/user_config.go @@ -325,7 +325,7 @@ func GetDefaultConfig() *UserConfig { Reporting: "undetermined", SplashUpdatesIndex: 0, ConfirmOnQuit: false, - QuitOnTopLevelReturn: true, + QuitOnTopLevelReturn: false, Keybinding: KeybindingConfig{ Universal: KeybindingUniversalConfig{ Quit: "q",