kahole / edamagit

Magit for VSCode

Home Page:https://marketplace.visualstudio.com/items?itemName=kahole.magit

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Feature Request: lockstep scrolling in file diff

matklad opened this issue · comments

TL;DR: when I use Magit: Diff File to open a diff to the side, I want the diff to be automatically scrolled to the file position I am in. That is, if I go to the last line in the file, I would also like the diff view to scroll to the last line as well.

Broader context in case this is an XY problem: when reviewing a large, complex pull request, my preferred workflow is to checkout the PR locally, and review the current state of the code (rather than the diff per se). However, I want to still be able to see the diff view to review lines deleted. So, my ideal view would be two-panes, where the left pane is the actual state of the file, and the left pane is a unified diff. Magit: Diff File gives me exactly this, except that I have to scroll the two views manually. If the scrolling was synchronized, that would be perfect!

Actually, I think this might be even more valuable for status.magit buffer? So that both the active file and the active hunk are revealed.