How get list submodules in git bare repo without create working tree?
(with low level library libgit2 or git console)?
Since the information is stored in .gitmodules at the root of the repo, the simplest way is to inspect that file without checking it out:
.gitmodules
git show HEAD:.gitmodules
I just tested, and this command works from within a bare repo, just as it would from a regular sandbox.
Since the information is stored in
.gitmodulesat the root of the repo, the simplest way is to inspect that file without checking it out:I just tested, and this command works from within a bare repo, just as it would from a regular sandbox.