]> git.ipfire.org Git - thirdparty/git.git/commit - t/t7400-submodule-basic.sh
submodule add: allow relative repository path even when no url is set
authorJens Lehmann <Jens.Lehmann@web.de>
Mon, 6 Jun 2011 19:58:04 +0000 (21:58 +0200)
committerJunio C Hamano <gitster@pobox.com>
Mon, 6 Jun 2011 20:46:36 +0000 (13:46 -0700)
commit4d689320049e1ff3bd31e0468d6f17eeb0b7029c
treeb3f96609e1df7afbb3640a8384721f39aa4098eb
parent8537f0ef936781d3984491603cd1c8ff15d7a8a5
submodule add: allow relative repository path even when no url is set

Adding a submodule with a relative repository path did only succeed when
the superproject's default remote was set. But when that is unset, the
superproject is its own authoritative upstream, so lets use its working
directory as upstream instead.

This allows users to set up a new superpoject where the submodules urls
are configured relative to the superproject's upstream while its default
remote can be configured later.

Signed-off-by: Jens Lehmann <Jens.Lehmann@web.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Documentation/git-submodule.txt
git-submodule.sh
t/t7400-submodule-basic.sh