mailing list mirror (one of many)
 help / Atom feed
From: Prathamesh Chavan <>
Cc:,,, Prathamesh Chavan <>
Subject: [PATCH v1 3/5] submodule foreach: clarify the '$toplevel' variable documentation
Date: Fri,  2 Feb 2018 10:27:43 +0530
Message-ID: <> (raw)
In-Reply-To: <>

It does not contain the topmost superproject as the author assumed,
but the direct superproject, such that $toplevel/$sm_path is the
actual absolute path of the submodule.

Discussed-with: Ramsay Jones <>
Signed-off-by: Stefan Beller <>
Signed-off-by: Prathamesh Chavan <>
 Documentation/git-submodule.txt | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/Documentation/git-submodule.txt b/Documentation/git-submodule.txt
index a23baef62..8e7930ebc 100644
--- a/Documentation/git-submodule.txt
+++ b/Documentation/git-submodule.txt
@@ -188,7 +188,8 @@ foreach [--recursive] <command>::
 	$name is the name of the relevant submodule section in `.gitmodules`,
 	$sm_path is the path of the submodule as recorded in the superproject,
 	$sha1 is the commit as recorded in the superproject, and
-	$toplevel is the absolute path to the top-level of the superproject.
+	$toplevel is the absolute path to its superproject, such that
+	$toplevel/$sm_path is the absolute path of the submodule.
 	Note that to avoid conflicts with '$PATH' on Windows, the '$path'
 	variable is now a deprecated synonym of '$sm_path' variable.
 	Any submodules defined in the superproject but not checked out are

  parent reply index

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-02-02  4:57 [PATCH v1 0/5] Incremental rewrite of git-submodules Prathamesh Chavan
2018-02-02  4:57 ` [PATCH v1 1/5] submodule foreach: correct '$path' in nested submodules from a subdirectory Prathamesh Chavan
2018-02-06 22:54   ` Jonathan Tan
2018-02-06 23:00     ` Jonathan Tan
2018-02-06 23:11     ` Stefan Beller
2018-02-02  4:57 ` [PATCH v1 2/5] submodule foreach: document '$sm_path' instead of '$path' Prathamesh Chavan
2018-02-02  4:57 ` Prathamesh Chavan [this message]
2018-02-02  4:57 ` [PATCH v1 4/5] submodule foreach: document variable '$displaypath' Prathamesh Chavan
2018-02-02  4:57 ` [PATCH v1 5/5] submodule: port submodule subcommand 'foreach' from shell to C Prathamesh Chavan

Reply instructions:

You may reply publically to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:

  List information:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \ \ \ \ \ \ \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link mailing list mirror (one of many)

Archives are clonable:
	git clone --mirror
	git clone --mirror http://ou63pmih66umazou.onion/git
	git clone --mirror http://czquwvybam4bgbro.onion/git
	git clone --mirror http://hjrcffqmbrq6wope.onion/git

Newsgroups are available over NNTP:

 note: .onion URLs require Tor:
       or Tor2web:

AGPL code for this site: git clone public-inbox