mirror of
https://github.com/jesseduffield/lazygit.git
synced 2026-10-06 05:57:38 -04:00
The staging view can hand the hunk you are on to an editor and apply what comes back, which is how you stage something the diff cannot express: half of a changed line, or a change written differently from either side. The focused main view has to be able to do the same before that view can go. The hunk is git's own, context and all, rather than lazygit's block of adjacent changes: an editable patch is one that still applies, and the context lines are what let git place it. What the editor leaves behind is applied whole rather than matched against the file's diff again, the point being that it says something the diff didn't. Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>