jesseduffield / lazygit

simple terminal UI for git commands
MIT License
47.94k stars 1.72k forks source link

Improve render performance #3686

Closed stefanhaller closed 1 week ago

stefanhaller commented 1 week ago

Fix a performance regression that I introduced with v0.41: when entering or leaving staging mode for a file, or when switching from a file that has only unstaged changes to one that has both staged and unstaged changes, there was a noticeable lag of about 500ms on my machine. With the improvements in this PR we get this back down to about 20ms.

Sits on top of #3685.

codacy-production[bot] commented 1 week ago

Coverage summary from Codacy

See diff coverage on Codacy

Coverage variation Diff coverage
Report missing for a62a5089d6ed5ba989279590a5bd3426829c856d[^1] :white_check_mark: 85.71%
Coverage variation details | | Coverable lines | Covered lines | Coverage | | ------------- | ------------- | ------------- | ------------- | | Common ancestor commit (a62a5089d6ed5ba989279590a5bd3426829c856d) | Report Missing | Report Missing | Report Missing | | | Head commit (26132cf5bdae7ec81e9a0708c722ad2a9cf0c2cf) | 52755 | 45699 | 86.62% | **Coverage variation** is the difference between the coverage for the head and common ancestor commits of the pull request branch: ` - `
Diff coverage details | | Coverable lines | Covered lines | Diff coverage | | ------------- | ------------- | ------------- | ------------- | | Pull request (#3686) | 42 | 36 | **85.71%** | **Diff coverage** is the percentage of lines that are covered by tests out of the coverable lines that the pull request added or modified: `/ * 100%`

See your quality gate settings    Change summary preferences


:rocket: Don’t miss a bit, follow what’s new on Codacy.

Codacy stopped sending the deprecated coverage status on June 5th, 2024. Learn more [^1]: Codacy didn't receive coverage data for the commit, or there was an error processing the received data. Check your integration for errors and validate that your coverage setup is correct.