Rescuing files and commits from "no branch" in git

Posted by Xeoncross on Super User See other posts from Super User or by Xeoncross
Published on 2010-03-04T16:51:19Z Indexed on 2010/12/21 20:56 UTC
Read the original article Hit count: 170

Filed under:
|

I started working on some files I had in a git submodule under another project. However, since it was a git submodule it never checked out "master" and instead just checked out the head and placed all the files in the folder in "no branch".

Now that I've made some changes by accident to these files I just realized that I was working in a "no branch", submodule of my project.

How do I get those files into a branch (like master) so I can rescue them?

© Super User or respective owner

Related posts about git

Related posts about submodule