When I run git status on my repo I get fatal: Not a git repository: /my repo/.git/modules/docs
I\'ve checked and .git exists and contains HEAD with the
Following @ax003d answer, you could replace all old paths (old/path) with the new path (new/path) using this command:
find . -type f \( -name ".git" -o \( -path "*.git/modules/*" -name config \) \) -print0 | xargs -0 sed -i -e "s#old/path#new/path#g"
You might want to check what the old paths look like before replacing them:
find . -type f \( -name ".git" -o \( -path "*.git/modules/*" -name config \) \) -print0 | xargs -0 grep --colour "old/path"