jesseduffield / jesseduffield/lazygit

Re-run diff pager on terminal size change

Open
#4,415 9 comments 5 reactions 0 assignees View on GitHub
bug
Dominant language
Go
Stars
82.4k
Forks
3k
Avg merge
2d 18h
Merged PRs (30d)
19

Description

**Describe the bug**

When the terminal is resized, the git diff isn't reproduced. This can mean line breaks don't get updated, eg. when using delta.

**To Reproduce**

1. Set delta (with colour) as your pager.
2. Open Lazygit to view a diff.
3. Resize the window.

**Expected behavior**

The pager should be re-run, ideally with an effort made to keep its view scrolled to the same place in the new terminal size.

**Screenshots**

Before resize:
![Image](https://github.com/user-attachments/assets/b708e4ff-21d2-474e-b645-59f8eb329d78)

After:
![Image](https://github.com/user-attachments/assets/2c6c8788-9e9b-40e8-8711-62fc33c6cb88)

**Version info:**

```
commit=, build date=, build source=voidlinux, version=0.48.0, os=linux, arch=amd64, git version=2.49.0
```

**Additional context**

n/a

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.