Even though many of my customers don't even know what a versionning system is, I like to work with them. So, I end up initing projects only on my local workstation. That allows me export only the modified files without being forced to remember the modified files and the modification made.
On my latest project, I did what I always do :
git add --all
git commit -m "Initial commit"
And I ended up with the following message :
fatal: bad object HEAD
fatal: 'git status --porcelain' failed in submodule modules/xxxx
I had absolutely no idea what the problem was. I googled, stackoverflowed and searched for a solution all over the web. You will have to admit that the error was not very precise and informative. I thought that the submodule the message was talking about was a git submodule.
Finnaly, a flash of intelligence made me realize that it was a module of my program (in Prestashop, the directory containing modules is called modules). This module had been developped using git and the production directory still contained the .git directory so my local git refused to commit anything or even to display a status of the repository.
Hope this will help.