1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2025-07-28 16:02:01 +03:00

remove viper

WIP
This commit is contained in:
Jesse Duffield
2020-10-03 14:54:55 +10:00
parent 9440dcf9de
commit 4912205adb
272 changed files with 10788 additions and 59939 deletions

View File

@ -24,7 +24,7 @@ func (c *GitCommand) ConfiguredPager() string {
}
func (c *GitCommand) GetPager(width int) string {
useConfig := c.Config.GetUserConfig().GetBool("git.paging.useConfig")
useConfig := c.Config.GetUserConfig().Git.Paging.UseConfig
if useConfig {
pager := c.ConfiguredPager()
return strings.Split(pager, "| less")[0]
@ -34,12 +34,12 @@ func (c *GitCommand) GetPager(width int) string {
"columnWidth": strconv.Itoa(width/2 - 6),
}
pagerTemplate := c.Config.GetUserConfig().GetString("git.paging.pager")
pagerTemplate := c.Config.GetUserConfig().Git.Paging.Pager
return utils.ResolvePlaceholderString(pagerTemplate, templateValues)
}
func (c *GitCommand) colorArg() string {
return c.Config.GetUserConfig().GetString("git.paging.colorArg")
return c.Config.GetUserConfig().Git.Paging.ColorArg
}
func (c *GitCommand) GetConfigValue(key string) string {