Is there a command that allows you to partially undo the changes to a file (or files) in the working directory?
Suppose you have edited a file a lot but you realize that you want to undo some of the changes back to the committed state, but not the other changes.
I'm envisioning an option for git checkout that works a lot like git add -p, i.e. it goes through the file hunk by hunk and asks if you want to keep it or not.