I have run the following git command to update my config:
git config --global submodule.recurse true
The entry in .gitconfig now looks like this:
[submodule]
recurse = true
My expectation was that afterwards a git pull would also update all my submodules. But running
git submodule update --init –recursive
again after the pull did still update some submodules.
Am I misunderstanding the effect of the config-setting or are there situations where git pull will still not update a submodule?
Is your issue that new submodules introduced by the pull aren't being created by git pull? If so then that is a known bug, see git help pull;
BUGS
Using --recurse-submodules can only fetch new commits in already checked out submodules right now. When e.g. upstream added a new submodule in the just fetched commits of the superproject the submodule itself can not be fetched, making it impossible to check out that submodule later without having to do a fetch again. This is expected to be fixed in a future Git version.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With