diff --git a/pkg/gui/controllers/basic_commits_controller.go b/pkg/gui/controllers/basic_commits_controller.go index b3a5bf38c..be856a9e9 100644 --- a/pkg/gui/controllers/basic_commits_controller.go +++ b/pkg/gui/controllers/basic_commits_controller.go @@ -1,7 +1,6 @@ package controllers import ( - "errors" "fmt" "strings" @@ -130,14 +129,6 @@ func (self *BasicCommitsController) GetKeybindings(opts types.KeybindingsOpts) [ GetDisabledReason: self.require(self.canSelectCommitsOfCurrentBranch), Description: self.c.Tr.SelectCommitsOfCurrentBranch, }, - // Putting this at the bottom of the list so that it has the lowest priority, - // meaning that if the user has configured another keybinding to the same key - // then that will take precedence. - { - // Hardcoding this key because it's not configurable - Key: opts.GetKey("c"), - Handler: self.handleOldCherryPickKey, - }, } return bindings @@ -382,16 +373,6 @@ func (self *BasicCommitsController) canCopyCommits(selectedCommits []*models.Com return nil } -func (self *BasicCommitsController) handleOldCherryPickKey() error { - msg := utils.ResolvePlaceholderString(self.c.Tr.OldCherryPickKeyWarning, - map[string]string{ - "copy": keybindings.Label(self.c.UserConfig().Keybinding.Commits.CherryPickCopy), - "paste": keybindings.Label(self.c.UserConfig().Keybinding.Commits.PasteCommits), - }) - - return errors.New(msg) -} - func (self *BasicCommitsController) openDiffTool(commit *models.Commit) error { to := commit.RefName() from, reverse := self.c.Modes().Diffing.GetFromAndReverseArgsForDiff(commit.ParentRefName()) diff --git a/pkg/i18n/english.go b/pkg/i18n/english.go index 970afd498..1be4898b1 100644 --- a/pkg/i18n/english.go +++ b/pkg/i18n/english.go @@ -897,7 +897,6 @@ type TranslationSet struct { SelectedItemIsNotABranch string SelectedItemDoesNotHaveFiles string MultiSelectNotSupportedForSubmodules string - OldCherryPickKeyWarning string CommandDoesNotSupportOpeningInEditor string CustomCommands string NoApplicableCommandsInThisContext string @@ -1993,7 +1992,6 @@ func EnglishTranslationSet() *TranslationSet { SelectedItemIsNotABranch: "Selected item is not a branch", SelectedItemDoesNotHaveFiles: "Selected item does not have files to view", MultiSelectNotSupportedForSubmodules: "Multiselection not supported for submodules", - OldCherryPickKeyWarning: "The 'c' key is no longer the default key for copying commits to cherry pick. Please use `{{.copy}}` instead (and `{{.paste}}` to paste). The reason for this change is that the 'v' key for selecting a range of lines when staging is now also used for selecting a range of lines in any list view, meaning that we needed to find a new key for pasting commits, and if we're going to now use `{{.paste}}` for pasting commits, we may as well use `{{.copy}}` for copying them. If you want to configure the keybindings to get the old behaviour, set the following in your config:\n\nkeybinding:\n universal:\n toggleRangeSelect: \n commits:\n cherryPickCopy: 'c'\n pasteCommits: 'v'", CommandDoesNotSupportOpeningInEditor: "This command doesn't support switching to the editor", CustomCommands: "Custom commands", NoApplicableCommandsInThisContext: "(No applicable commands in this context)",