4.7. Gotchas for Submodules#
Submodules Do Not Update Automatically ⚠️: Submodules are not automatically updated to the latest commit.
Repository Resides in the
.gitFolder of the Parent Repo 🔒: The metadata for Submodules is stored in the parent repository’s.gitfolder.Submodule Commits Are Detached : Submodules are designed to be pinned to a specific commit and do not track a branch.
Submodule URLs Can Change 🔗: You might need to update the
.gitmodulesfile manually.Cloning with Submodules Requires Extra Steps 🛠️: Remember to use the
--recurse-submoduleoption when cloning.Submodules Can Increase Complexity 🌀: This might be confusing for newcomers.