diff options
Diffstat (limited to 'pkg/gui/modes.go')
-rw-r--r-- | pkg/gui/modes.go | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/pkg/gui/modes.go b/pkg/gui/modes.go index af8977989..92b7d3171 100644 --- a/pkg/gui/modes.go +++ b/pkg/gui/modes.go @@ -1,6 +1,7 @@ package gui import ( + "github.com/jesseduffield/lazygit/pkg/commands" "github.com/jesseduffield/lazygit/pkg/gui/style" ) @@ -58,5 +59,19 @@ func (gui *Gui) modeStatuses() []modeStatus { }, reset: gui.exitCherryPickingMode, }, + { + isActive: func() bool { + return gui.GitCommand.WorkingTreeState() != commands.REBASE_MODE_NORMAL + }, + description: func() string { + workingTreeState := gui.GitCommand.WorkingTreeState() + return style.FgYellow.Sprintf( + "%s %s", + workingTreeState, + style.AttrUnderline.Sprint(gui.Tr.ResetInParentheses), + ) + }, + reset: gui.abortMergeOrRebaseWithConfirm, + }, } } |