X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=Documentation%2Furls.txt;h=fa34c6747194aaecf9e8124462129b8bbc9ae7d4;hb=1eaa541f5fbda3fc30085da4f75e99dfae4ec9b3;hp=81ac17f32a0587e3d2d41eb8ee89dd85e13f1802;hpb=e98d6df75260312e906278705f78f2eee39cc8fc;p=git.git diff --git a/Documentation/urls.txt b/Documentation/urls.txt index 81ac17f32..fa34c6747 100644 --- a/Documentation/urls.txt +++ b/Documentation/urls.txt @@ -44,3 +44,26 @@ endif::git-clone[] ifdef::git-clone[] They are equivalent, except the former implies --local option. endif::git-clone[] + + +If there are a large number of similarly-named remote repositories and +you want to use a different format for them (such that the URLs you +use will be rewritten into URLs that work), you can create a +configuration section of the form: + +------------ + [url ""] + insteadOf = +------------ + +For example, with this: + +------------ + [url "git://git.host.xz/"] + insteadOf = host.xz:/path/to/ + insteadOf = work: +------------ + +a URL like "work:repo.git" or like "host.xz:/path/to/repo.git" will be +rewritten in any context that takes a URL to be "git://git.host.xz/repo.git". +