I was doing some work in my repository and noticed a file had local changes. I didn’t want them anymore so I deleted the file, thinking I can just checkout a fresh copy. I wanted to do the Git equivalent of
svn up .
git pull didn’t seem to work. Some random searching led me to a site where someone recommended doing
git checkout HEAD^ src/
src is the directory containing the deleted file).
Now I find out I have a detached head. I have no idea what that is. How can I undo?