diff --git a/pkg/config/user_config.go b/pkg/config/user_config.go index e4a10e10b..1312e4bd8 100644 --- a/pkg/config/user_config.go +++ b/pkg/config/user_config.go @@ -1,9 +1,5 @@ package config -import ( - "github.com/jesseduffield/lazygit/pkg/secureexec" -) - type UserConfig struct { Gui GuiConfig `yaml:"gui"` Git GitConfig `yaml:"git"` @@ -327,7 +323,7 @@ func GetDefaultConfig() *UserConfig { Args: "", }, Pull: PullConfig{ - Mode: getPullModeFromGitConfig(), + Mode: "merge", }, SkipHookPrefix: "WIP", AutoFetch: true, @@ -489,17 +485,3 @@ func GetDefaultConfig() *UserConfig { NotARepository: "prompt", } } - -func getPullModeFromGitConfig() string { - rebaseOut, rebaseErr := secureexec.Command("git config --get pull.rebase").Output() - if rebaseErr == nil && rebaseOut[0] == 't' { - return "rebase" - } - - ffOut, ffErr := secureexec.Command("git config --get pull.ff").Output() - if ffErr == nil && ffOut[0] == 't' { - return "ff-only" - } - - return "merge" -}