summaryrefslogtreecommitdiffstats
path: root/pkg/gui/presentation/working_tree.go
blob: 1e1954bc98592c3ee812392b399d02b804435027 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
package presentation

import (
	"github.com/jesseduffield/lazygit/pkg/commands/types/enums"
	"github.com/jesseduffield/lazygit/pkg/i18n"
)

func FormatWorkingTreeStateTitle(tr *i18n.TranslationSet, rebaseMode enums.RebaseMode) string {
	switch rebaseMode {
	case enums.REBASE_MODE_REBASING:
		return tr.RebasingStatus
	case enums.REBASE_MODE_MERGING:
		return tr.MergingStatus
	default:
		// should never actually display this
		return "none"
	}
}

func FormatWorkingTreeStateLower(tr *i18n.TranslationSet, rebaseMode enums.RebaseMode) string {
	switch rebaseMode {
	case enums.REBASE_MODE_REBASING:
		return tr.LowercaseRebasingStatus
	case enums.REBASE_MODE_MERGING:
		return tr.LowercaseMergingStatus
	default:
		// should never actually display this
		return "none"
	}
}