0

I am a bit new to git and would like some help with this. so here is what happened. I have a total of 6 commits in a branch, now I need to reset any changes made by me to specifically 2 files- abc.txt and xyz.txt

How can I achieve this? any help on this is highly appreciated. Thanks in advance.

1 Answers1

1

If you just want to revert to the latest commit, try

git checkout abc.txt xyz.txt

If there's a specific commit you want to revert to, try

git checkout <commit> abc.txt xyz.txt
bchurchill
  • 1,410
  • 8
  • 23