diff options
author | Jesse Duffield <jessedduffield@gmail.com> | 2020-10-04 11:00:48 +1100 |
---|---|---|
committer | Jesse Duffield <jessedduffield@gmail.com> | 2020-10-10 00:23:01 +1100 |
commit | 37bb89dac33cb4236bf817e1e2e09cb1cbfade5c (patch) | |
tree | ea06fa4595a7f2d7eff80c2602648b18450f5988 /pkg/gui/commit_message_panel.go | |
parent | 7d9aa97f9691dd0a8658c4b6626877a198c5d03c (diff) |
type i18n
Diffstat (limited to 'pkg/gui/commit_message_panel.go')
-rw-r--r-- | pkg/gui/commit_message_panel.go | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/pkg/gui/commit_message_panel.go b/pkg/gui/commit_message_panel.go index 3db714fa2..4a5597659 100644 --- a/pkg/gui/commit_message_panel.go +++ b/pkg/gui/commit_message_panel.go @@ -6,6 +6,7 @@ import ( "strings" "github.com/jesseduffield/gocui" + "github.com/jesseduffield/lazygit/pkg/utils" ) // runSyncOrAsyncCommand takes the output of a command that may have returned @@ -28,7 +29,7 @@ func (gui *Gui) runSyncOrAsyncCommand(sub *exec.Cmd, err error) (bool, error) { func (gui *Gui) handleCommitConfirm(g *gocui.Gui, v *gocui.View) error { message := gui.trimmedContent(v) if message == "" { - return gui.createErrorPanel(gui.Tr.SLocalize("CommitWithoutMessageErr")) + return gui.createErrorPanel(gui.Tr.CommitWithoutMessageErr) } flags := "" skipHookPrefix := gui.Config.GetUserConfig().Git.SkipHookPrefix @@ -53,14 +54,15 @@ func (gui *Gui) handleCommitClose(g *gocui.Gui, v *gocui.View) error { } func (gui *Gui) handleCommitMessageFocused() error { - message := gui.Tr.TemplateLocalize( - "CommitMessageConfirm", - Teml{ + message := utils.ResolvePlaceholderString( + gui.Tr.CommitMessageConfirm, + map[string]string{ "keyBindClose": "esc", "keyBindConfirm": "enter", "keyBindNewLine": "tab", }, ) + gui.renderString("options", message) return nil } |