mirror of
https://github.com/jesseduffield/lazygit.git
synced 2025-02-25 18:55:28 -06:00
extend cheatsheet generator to contain context based keybindings
This commit is contained in:
@@ -13,7 +13,6 @@ type Binding struct {
|
||||
Key interface{} // FIXME: find out how to get `gocui.Key | rune`
|
||||
Modifier gocui.Modifier
|
||||
Description string
|
||||
panic bool
|
||||
}
|
||||
|
||||
// GetDisplayStrings returns the display string of a file
|
||||
@@ -32,10 +31,6 @@ func (b *Binding) GetKey() string {
|
||||
key = int(b.Key.(gocui.Key))
|
||||
}
|
||||
|
||||
if b.panic {
|
||||
panic(key)
|
||||
}
|
||||
|
||||
// special keys
|
||||
switch key {
|
||||
case 27:
|
||||
|
||||
@@ -311,10 +311,10 @@ func addEnglish(i18nObject *i18n.Bundle) error {
|
||||
Other: "revert commit", // TODO: i18n
|
||||
}, &i18n.Message{
|
||||
ID: "OnlyRenameTopCommit",
|
||||
Other: "Can only rename topmost commit from within lazygit. Use shift+R instead",
|
||||
Other: "Can only reword topmost commit from within lazygit. Use shift+R instead",
|
||||
}, &i18n.Message{
|
||||
ID: "renameCommit",
|
||||
Other: "rename commit",
|
||||
Other: "reword commit",
|
||||
}, &i18n.Message{
|
||||
ID: "deleteCommit",
|
||||
Other: "delete commit", // TODO: other languages
|
||||
|
||||
Reference in New Issue
Block a user