Rescuing files and commits from "no branch" in git
- by Xeoncross
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?