Is there a way to unstage/revert single lines of changes using Git GUI? How can I do that?
I am a long time Atom user. Here I had the option to revert single lines or multiple selected lines of staged code as shown in the image:
Is there a way to unstage/revert single lines of changes using Git GUI? How can I do that?
I am a long time Atom user. Here I had the option to revert single lines or multiple selected lines of staged code as shown in the image:
Do you mean something like this : IntelliJ single line commit/revert
I never used Git GUI so I can't directly answer your question but some IDE have git plugin allowing you to select which line of change you want to commit or revert.
I guess you could also use a merge tool like kdiff3 or winMerge which have nice interface to select which part of the file you actually want to keep or not.
Edit :
Found this https://mfranc.com/blog/git-git-gui-staging-selected-lines/. I tried it on my side, if there are 2 lines as a block I cannot manage to push only one (but I have the same with my IDE). In the settings there is an option "number of diff context lines" that I though would solve the issue but I don't see the impact.