git: revert (reset) a single file
If you have an uncommitted change (its only in your working copy) that you wish to revert (in SVN terms) to the copy in your latest commit, do the following:
git checkout filename
This will checkout the file from HEAD, overwriting your change.
The rest of the Internet will tell you to use git reset --hard, but this resets all uncommitted changes you’ve made in your working copy. Type this with care.
files
tips
howto
revision
git