mirror of
https://github.com/jesseduffield/lazygit.git
synced 2026-10-06 14:06:32 -04:00
When somebody else rebases a branch and force-pushes it, our branch shows up as diverged, say ↓5↑3, and that looks exactly like a branch that carries three commits of our own. The two want different treatment. The first one only has to be moved to its upstream, while the second one needs a decision about what to do with those commits. The panel doesn't tell them apart, so users have to look at each branch in turn to find out which one they are dealing with. Determine for every diverged branch whether it has commits of its own, and dim its divergence when it doesn't. This runs on a worker, as it takes a few git commands per diverged branch, and a branch keeps the answer from the previous load while a new one is in flight, so that the display doesn't flicker. A later commit teaches the fast-forward command to act on such a branch. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>