Skip to content

Commit b6c8d2d

Browse files
artagnongitster
authored andcommitted
Documentation/remote-helpers: Add invocation section
Add an 'Invocation' section to specify what the command line arguments mean. Also include a link to git-remote in the 'See Also' section. Signed-off-by: Ramkumar Ramachandra <[email protected]> Acked-by: Sverre Rabbelier <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 5ce4f4e commit b6c8d2d

File tree

1 file changed

+34
-1
lines changed

1 file changed

+34
-1
lines changed

Documentation/git-remote-helpers.txt

Lines changed: 34 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ git-remote-helpers - Helper programs to interact with remote repositories
77

88
SYNOPSIS
99
--------
10-
'git remote-<transport>' <remote>
10+
'git remote-<transport>' <repository> [<URL>]
1111

1212
DESCRIPTION
1313
-----------
@@ -39,6 +39,35 @@ transport protocols, such as 'git-remote-http', 'git-remote-https',
3939
'git-remote-ftp' and 'git-remote-ftps'. They implement the capabilities
4040
'fetch', 'option', and 'push'.
4141

42+
INVOCATION
43+
----------
44+
45+
Remote helper programs are invoked with one or (optionally) two
46+
arguments. The first argument specifies a remote repository as in git;
47+
it is either the name of a configured remote or a URL. The second
48+
argument specifies a URL of the form '<transport>://<address>' or
49+
'<transport>::<address>', where '<address>' may be an arbitrary
50+
string.
51+
52+
When git encounters a URL of the form '<transport>://<address>', where
53+
'<transport>' is a protocol that it cannot handle natively, it
54+
automatically invokes 'git remote-<transport>' with the full URL as
55+
the second argument. If such a URL is encountered directly on the
56+
command line, the first argument is the same as the second, and if it
57+
is encountered in a configured remote, the first argument is the name
58+
of that remote.
59+
60+
A URL of the form '<transport>::<address>' explicitly instructs git to
61+
invoke 'git remote-<transport>' with '<address>' as the second
62+
argument. If such a URL is encountered directly on the command line,
63+
the first argument is '<address>', and if it is encountered in a
64+
configured remote, the first argument is the name of that remote.
65+
66+
Additionally, when a configured remote has 'remote.<name>.vcs' set to
67+
'<transport>', git explicitly invokes 'git remote-<transport>' with
68+
'<name>' as the first argument. If set, the second argument is
69+
'remote.<name>.url'; otherwise, the second argument is omitted.
70+
4271
COMMANDS
4372
--------
4473

@@ -212,6 +241,10 @@ OPTIONS
212241
helper MUST NOT rely on this option being set before
213242
connect request occurs.
214243

244+
SEE ALSO
245+
--------
246+
linkgit:git-remote[1]
247+
215248
Documentation
216249
-------------
217250
Documentation by Daniel Barkalow and Ilari Liusvaara

0 commit comments

Comments
 (0)