fatal: Pathspec 'autoload_classmap.php' is in submodule 'module/CocktailMakerModule'

git

Solution

Still no idea how it happened. All documentation I read assumes I have a `.git` directory there but I don't.

I just did the following:

git rm -rf --cached CocktailMakerModule/
git add CocktailMakerModule/

That seems to resolve the issue.

Problem

I have a repository on google code with my project. I use Git source control. It seems that when I try to add files to git from a specific directory, I get the following error: ``` fatal: Pathspec 'autoload_classmap.php' is in submodule 'module/CocktailMakerModule' ``` Now I'm not trying to add a submodule. I'm just trying to add a directory to git! The result that I have now is that this directory is committed empty. So when I try to add specific files I get the above error message. I checked and there isn't any other `.git` directory in that directory, so I'm really confused to why this has happened.

Original source

Related problems