1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2024-11-28 09:08:41 +02:00

Use a PTY when calling external diff command (#3120)

This commit is contained in:
Stefan Haller 2023-11-22 12:51:02 +01:00 committed by GitHub
commit d8059d7f7d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -45,8 +45,9 @@ func (gui *Gui) onResize() error {
func (gui *Gui) newPtyTask(view *gocui.View, cmd *exec.Cmd, prefix string) error {
width, _ := gui.Views.Main.Size()
pager := gui.git.Config.GetPager(width)
externalDiffCommand := gui.Config.GetUserConfig().Git.Paging.ExternalDiffCommand
if pager == "" {
if pager == "" && externalDiffCommand == "" {
// if we're not using a custom pager we don't need to use a pty
return gui.newCmdTask(view, cmd, prefix)
}