Hacker News new | ask | show | jobs
by fishywang 1913 days ago
>If there are new commits in a submodule, why doesn't `git checkout .` reset it back to the commit the main repo points to?

>If I clone a repo with submodules, why do I need to run additional submodule commands to get an exact copy of the codebase?

`git config [--global] submodule.recurse true` resolves both questions.

As to why is that not the default? I _believe_ there are security concerns, but I'm not 100% sure.