Why do I get "fatal: git status --porcelain failed"?

Ahmed Nuaman picture Ahmed Nuaman · Mar 28, 2011 · Viewed 27k times · Source

This is a huge pain in the bum. I've got this a few times before and I don't understand why. 5 mins ago the repo was fine and working, I move some files around (which is all cool and all) and git poops its pants. Any idea why this happens? How can I fix it apart from cloning the repo, moving the files, etc...

Answer

Ahmed Nuaman picture Ahmed Nuaman · Mar 28, 2011

Oh dear I'm such a fail. It looks like the problem stems from Flash Builder copying over other .git repos into sub folders. The answer is to remove all .git folders that aren't the repo's one.