1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2025-07-30 03:23:08 +03:00

refactor custom commands

more custom command refactoring
This commit is contained in:
Jesse Duffield
2022-02-24 13:29:48 +11:00
parent 952a4f3f23
commit ef7c4c9ca9
13 changed files with 701 additions and 391 deletions

View File

@ -1116,7 +1116,11 @@ func (gui *Gui) resetKeybindings() error {
bindings, mouseBindings := gui.GetInitialKeybindings()
// prepending because we want to give our custom keybindings precedence over default keybindings
bindings = append(gui.GetCustomCommandKeybindings(), bindings...)
customBindings, err := gui.CustomCommandsClient.GetCustomCommandKeybindings()
if err != nil {
log.Fatal(err)
}
bindings = append(customBindings, bindings...)
for _, binding := range bindings {
if err := gui.SetKeybinding(binding); err != nil {