Git undo changes in some files [duplicate]

While coding I added print statements into some files to keep track of what was going on.

When I am done, is it possible to revert changes in some files, but commit the file I actually worked on?

Say I added print in file A, but I modified file B. B is what I want to commit and A, I want to be set back to its old state.

6 Answers
6

Leave a Comment