Archive for May, 2009

svn revert equivalent in git

Tuesday, May 26th, 2009

I keep wanting to type

git revert

to roll back changes to the last committed version of something—that’s how you’d do it in Subversion—but this isn’t right. This works instead:

git reset --hard HEAD