Retrospectively add –recursive to a git repo

You can do it with this after a simple top-level clone:

git submodule update --init --recursive

I would not recommend making clone do this by default. The proper way to do this if you are using submodules aggressively for development and not just linking to 3rd party OSS libs on github that you may upgrade once in a blue moon, is to use git slave or subtree.

Leave a Comment