1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2025-01-20 05:19:24 +02:00

add oneline-graph

This commit is contained in:
Jasper Mendiola 2020-07-10 16:22:22 +08:00 committed by Jesse Duffield
parent e82d2f37a1
commit e89bf5d06b
3 changed files with 7 additions and 1 deletions

View File

@ -43,6 +43,7 @@ Default path for the config file:
args: ""
skipHookPrefix: WIP
autoFetch: true
branchLogCmd: "git log --graph --color=always --abbrev-commit --decorate --date=relative --pretty=medium {{branchName}} --"
update:
method: prompt # can be: prompt | background | never
days: 14 # how often an update is checked for

View File

@ -635,7 +635,11 @@ func (c *GitCommand) ShowCmdStr(sha string, filterPath string) string {
}
func (c *GitCommand) GetBranchGraphCmdStr(branchName string) string {
return fmt.Sprintf("git log --graph --color=always --abbrev-commit --decorate --date=relative --pretty=medium %s --", branchName)
branchLogCmdTemplate := c.Config.GetUserConfig().GetString("git.branchLogCmd")
templateValues := map[string]string{
"branchName": branchName,
}
return utils.ResolvePlaceholderString(branchLogCmdTemplate, templateValues)
}
// GetRemoteURL returns current repo remote url

View File

@ -270,6 +270,7 @@ git:
args: ""
skipHookPrefix: 'WIP'
autoFetch: true
branchLogCmd: "git log --graph --color=always --abbrev-commit --decorate --date=relative --pretty=medium {{branchName}} --"
update:
method: prompt # can be: prompt | background | never
days: 14 # how often a update is checked for