git status shows fatal: bad object HEAD

前端 未结 14 1337
醉酒成梦
醉酒成梦 2020-12-09 00:44

I have a problem with git on Windows Azure. Git status shows - \"fatal: bad object HEAD\" and I tried running:

 git fsck --full
 git gc

But

14条回答
  •  借酒劲吻你
    2020-12-09 01:12

    try this : worked for me rm -rf .git

    You can use mv instead of rm if you don't want to loose your stashed commits

    then copy .git from other clone

    cp /.git . -r

    then do

    git init

    this should solve your problem , ALL THE BEST

提交回复
热议问题