So I\'ve done some work in the repository and when I\'m about to commit I realize that I\'m not currently on any branch.
This happens a lot when working with submodu
this helped me
git checkout -b newbranch git checkout master git merge newbranch git branch -d newbranch