After cloning, the submodule directories exist but are empty.
BeginnerTroubleshootingSubmodules, LFS and Hooks
Answer
Likely causes → A plain git clone does not fetch submodule contents; it only creates empty directories for the gitlinks.
Diagnose → git submodule status — a leading - means not initialized.
Fix →
git submodule update --init --recursive
# next time:
git clone --recurse-submodules https://github.com/org/app.git
Prevent → Set git config --global submodule.recurse true so checkout, pull and switch keep submodules in sync, and document the clone command in the README.
More on Submodules, LFS and Hooks
`fatal: No url found for submodule path 'libs/common' in .gitmodules`Intermediate`git submodule update` fails: `fatal: remote error: upload-pack: not our ref 3f2a9c1...` and `Fetched in submodule path 'libs/common', but it did not contain 3f2a9c1. Direct fetching of that commit failed.`Intermediate`git status` keeps showing `modified: libs/common (new commits)` even though you never touched it.BeginnerYou committed inside a submodule, ran `git submodule update`, and your commits vanished.Intermediate`git submodule add` fails with `fatal: 'libs/common' already exists in the index`.IntermediateRe-adding a removed submodule fails: `A git directory for 'libs/common' is found locally with remote(s): origin https://github.com/org/common.git`.Advanced