mirror of
https://github.com/jesseduffield/lazygit.git
synced 2026-09-15 01:56:24 -04:00
The patch package can already map a patch line index to its new-file line number and back (LineNumberOfLine / PatchLineForLineNumber). The diff-line parser being built on top of this needs the old-file equivalents: a deletion has no distinct new-file position (two consecutive deletions share one), so to land on the exact deletion when diving into staging we have to look it up by old-file line number. Add OldLineNumberOfLine and PatchLineForOldLineNumber as direct mirrors of the new-file functions, counting DELETION+CONTEXT lines instead of ADDITION+CONTEXT. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| app | ||
| cheatsheet | ||
| commands | ||
| common | ||
| config | ||
| constants | ||
| env | ||
| fakes | ||
| gocui | ||
| gui | ||
| i18n | ||
| integration | ||
| jsonschema | ||
| logs | ||
| snake | ||
| tasks | ||
| theme | ||
| updates | ||
| utils | ||