Open goran-w opened 1 week ago
SourceGit provides support for external comparison tools, which means that in this project, the built-in comparison view will only implement some basic functions.
As you mentioned above, this feature is also unnecessary until the entire file display feature is added, because SourceGit
only displays a limited context.
I find it unfortunate to have to resort to external tools for this, when the built-in Diff is much more convenient for quick (re)viewing of changes. Having to popup an external tool takes extra time and disrupts the workflow - I would prefer to only use that for resolving merge conflicts. Viewing the whole file (#615) and being able to navigate quickly between changes would improve this tool a lot, IMHO. (Would you be willing to accept a PR for this, eventually?)
I don't see why the navigation buttons shouldn't be available regardless of whether the entire file is displayed or not. Navigation could happen within the lines that are loaded. This feature, combined with the addition of keyboard shortcuts to accept or reject a block of changes, would make keyboard operation easier.
Because the context line number is not large enough, go to next/prev change just like page down/up
Instead of simply scrolling through changes, I believe the optimal approach would be to automatically select the next difference block upon navigation. This way, I can utilize keyboard shortcuts to discard or accept changes efficiently, ensuring smooth commit review even when the context is limited. This keyboard-centric approach streamlines the entire process and significantly enhances productivity.
I agree - keyboard shortcuts for navigating up/dn to each change (instead of just PgUp/Dn) and for stage/discard would be a great workflow.
The built-in Diff viewer has no way to navigate quickly to the previous or next change (or hunk). This would be very helpful, especially if also implementing #615.
I suggest adding icon-toggles (up-down arrows) for "Prev(ious)/Next Change" (with corresponding hotkeys) in the top (mini-)bar of the built-in Diff viewer.
For reference, SmartGit and GitKraken has this feature, and it's also very common in standalone diff/merge vievers like P4Merge, Meld etc.