Interview Prep/Git & GitHub/Submodules, LFS and Hooks

`git status` keeps showing `modified: libs/common (new commits)` even though you never touched it.

BeginnerTroubleshootingSubmodules, LFS and Hooks
Answer

Likely causes → The submodule's checked-out commit differs from what the superproject records. Typically you pulled the parent (which bumped the gitlink) without updating submodules, or someone ran git pull inside the submodule.

Diagnose →

git diff --submodule=log libs/common
git submodule status

Fix → To match the parent: git submodule update --init libs/common. If you really want the new submodule commit, commit the bump: git add libs/common && git commit -m "Bump common to v1.4.0".

Prevent → submodule.recurse=true and status.submoduleSummary=true make this visible and automatic.

All Git & GitHub questions Roadmap: Git & GitHub

More on Submodules, LFS and Hooks