on Mon Aug 05 2013, Ahmed Charles
Each subsection of .gitmodules would look like:
[submodule "smart_ptr"] path = libs/smart_ptr url = http://github.com/boostorg/smart_ptr.git fetchRecurseSubmodules = on-demand
But I don't see why that should make any difference whatsoever. There are no sub-submodules. At least, not yet.
What am I missing?
The docs say: This option can be used to control recursive fetching of this submodule. If this option is also present in the submodules entry in .git/config of the superproject, the setting there will override the one found in .gitmodules. Both settings can be overridden on the command line by using the "--[no-]recurse-submodules" option to "git fetch" and "git pull".
The docs for "git fetch --recurse-submodules[=yes|on-demand|no]" says:
This option controls if and under what conditions new commits of populated submodules should be fetched too. It can be used as a boolean option to completely disable recursion when set to no or to unconditionally recurse into all populated submodules when set to yes, which is the default when this option is used without any value. Use on-demand to only recurse into a populated submodule when the superproject retrieves a commit that updates the submodule's reference to a commit that isn't already in the local submodule clone.
Oh, yeah; on-demand is clearly what we want!
Basically, what you are missing is that the setting applies to the submodule whose section it appears in and not submodules of that submodule.
Gotcha. Should be an easy fix. OK, done (https://github.com/ryppl/Boost2Git/commit/2d6fe0505ca54c8931fda7c1c87ee246a6...). -- Dave Abrahams