On Wed, Jan 28, 2009 at 01:19:13PM +0100, Tomas Carnecky wrote: > > Oops, sorry. git checkout HEAD -- d.txt > You have to tell which version of d.txt you want. In your case the > version in HEAD. > I use this command enough that I have this defined as an alias in my ~/.gitconfig file. Try running this command: git config --global alias.revert-file "checkout HEAD --" Now you will be able to do this: git revert-file d.txt This is also useful when I've edited d.txt, and decided that I didn't go about it the right away, and so I want to revert my edits. - Ted -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html