[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: editing a VC diff to modify the current version
From: |
emacsq |
Subject: |
Re: editing a VC diff to modify the current version |
Date: |
Thu, 24 Feb 2022 04:19:04 +0000 |
> When I modify a file under VC then I always make a diff before checkin to see
> everything is right. Sometimes the changes have a typo or a simple
> modification occurs to me which could be done right in the diff. With vscode
> you can actually edit the diff and the changes are reflected back to the
> current version, so you don't have to go back to the file, do the
> modifications, make a diff again to see everything is right, etc.
Also, you can stage/unstage or revert selected ranges in the diff which is also
handy:
https://user-images.githubusercontent.com/4114656/50283979-79913e00-044f-11e9-910f-c8b878148132.png
I'm not sure if a range here is equivalent to a diff hunk or you can
stage/revert parts of a hunk which could also be useful.
I know I can split a hunk in emacs diff mode, and it also occured to me if
emacs could support reverting some lines, or even just a region within lines,
without having to split the hunk first manually .