Skip to content
Novus Examples
gitmodules

What is a .gitmodules file?

text/plain

A .gitmodules file records the submodules of a Git repository. It uses the same INI-like grammar as .gitconfig, with one `[submodule "name"]` section per entry holding the working-tree `path`, the `url` to clone from, and optionally `branch`, `update`, `shallow`, and `ignore` settings. It is tracked in the repository, unlike the resolved submodule state, which lives in the index as gitlink entries.

How to use a .gitmodules file

Use an example .gitmodules file to test submodule-aware tooling, dependency scanners, and configuration parsers, verifying that section names and working-tree paths are read independently and that relative URLs are resolved against the parent remote.

Convert a .gitmodules file to another format

← All file formats