I am getting fatal: Failed to resolve HEAD as a valid ref. whenever I try to commit.
I have tried
echo ref: refs/heads/master >.git/HEAD
but its not working
its not working either from below sources
Please help in..All my commit history is also gone
You can re-clone then copy > paste your entire directory with the changes into the new clone directory and do git status to confirm all your changes were copied.
What do you see in the output from
I had a git in a dropbox folder once that got corrupted because of dropbox. Got into the habit of having both a real remote remote and a 2nd remote pointing to another clone on the same machine and pushing to both so just in case one gets corrupted I can just clone the other local one and if my house burns down I still have the remote in the cloud also.
Badges are a great way to show off community activity, whether you’re a newbie or a Champion.Learn more
Supported Platforms macOS Windows To make using Sourcetree as simple yet powerful as possible we embed (bundle) dependencies such as Git, Git LFS, and Mercurial. We strive to keep these...
Connect with like-minded Atlassian users at free events near you!Find a group
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no AUG chapters near you at the moment.Start an AUG
You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs