]> git.ipfire.org Git - thirdparty/git.git/commit
builtin/submodule--helper: add gitdir command
authorAdrian Ratiu <adrian.ratiu@collabora.com>
Mon, 12 Jan 2026 18:46:24 +0000 (20:46 +0200)
committerJunio C Hamano <gitster@pobox.com>
Mon, 12 Jan 2026 19:56:55 +0000 (11:56 -0800)
commit34206caaf7c5059ac8480587e31cfc40473002b4
tree3e48a27cd48016bcda9f1562e3966076893d8d56
parent05a1cdb5255b2b438e66bdaa91b7b2ce75fbe71b
builtin/submodule--helper: add gitdir command

This exposes the gitdir name computed by submodule_name_to_gitdir()
internally, to make it easier for users and tests to interact with it.

Next commit will add a gitdir configuration, so this helper can also be
used to easily query that config or validate any gitdir path the user
sets (submodule_name_to_git_dir now runs the validation logic, since
our previous commit).

Based-on-patch-by: Brandon Williams <bwilliams.eng@gmail.com>
Signed-off-by: Adrian Ratiu <adrian.ratiu@collabora.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/submodule--helper.c