You can try soft resetting the commit in which the files that you want have changes using the command : git reset --soft commitid
. After that you can use the following command to reset that single file to the HEAD as you see fit.
You can use the following command to reset the changes for a particular file to index:
git checkout -- CONTRIBUTING.md
The following command will reset the file to HEAD ,this will update both the working copy and the index to HEAD:
git checkout HEAD -- CONTRIBUTING.md
Reference:
https://git-scm.com/docs/git-checkout
Or another method i think that will work is :
- Soft reset the commit that have the changes on files you want to
edit
- Commit again with the files that you don't want to edit leaving out just your
J/Views/CardsTab/CardsTab.xaml
- Reset the branch to the last commit
This should leave your working branch clean with only your desired changes.