git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH] gitmodules.5: url can be a relative path

From
Jonathan Nieder <jrnieder@gmail.com>
Date
Jul 15, 2010, 07:41 UTC
Message-ID
<20100715074155.GA22244@burratino>
In-Reply-To
<alpine.DEB.2.00.1007150745340.13735@perkele.intern.softwolves.pp.se>

There is already excellent documentation for this facility in git-submodule.1, but it is not so discoverable.

Relative paths in .gitmodules can be useful for serving the same repository over multiple protocols, for example. Thanks to Peter for pointing this out.

Cc: Peter Krefting <peter@softwolves.pp.se>
Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
---
 Documentation/gitmodules.txt |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/Documentation/gitmodules.txt b/Documentation/gitmodules.txt
index 5daf750..72a13d1 100644
--- a/Documentation/gitmodules.txt
+++ b/Documentation/gitmodules.txt
@@ -29,6 +29,9 @@ submodule.<name>.path::
 
 submodule.<name>.url::
 	Defines an url from where the submodule repository can be cloned.
+	This may be either an absolute URL ready to be passed to
+	linkgit:git-clone[1] or (if it begins with ./ or ../) a location
+	relative to the superproject's origin repository.
 
 submodule.<name>.update::
 	Defines what to do when the submodule is updated by the superproject.
-- 
1.7.2.rc2
Previous: Peter KreftingNext: Jonathan Nieder
Message 7 of 12 in “serving git with both "git:" and "http:" and submodules”
  1. Boaz HarroshJul 14, 2010
  2. Jonathan NiederJul 14, 2010
  3. Boaz HarroshJul 14, 2010
  4. Jonathan NiederJul 14, 2010
  5. Brad KingJul 15, 2010
  6. Peter KreftingJul 15, 2010
  7. gitmodules.5: url can be a relative pathJonathan Nieder, Jul 15, 2010
  8. Documentation: add submodule.* to the big configuration variable listJonathan Nieder, Jul 15, 2010
  9. Johan HerlandJul 15, 2010
  10. Jonathan NiederJul 15, 2010
  11. Johan HerlandJul 15, 2010
  12. Boaz HarroshJul 15, 2010

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.