Documentation / urls.txton commit git-merge: make it usable as the first class UI (17bcdad)
   1GIT URLS[[URLS]]
   2----------------
   3
   4One of the following notations can be used
   5to name the remote repository:
   6
   7===============================================================
   8- rsync://host.xz/path/to/repo.git/
   9- http://host.xz/path/to/repo.git/
  10- https://host.xz/path/to/repo.git/
  11- git://host.xz/path/to/repo.git/
  12- git://host.xz/~user/path/to/repo.git/
  13- ssh://{startsb}user@{endsb}host.xz/path/to/repo.git/
  14- ssh://{startsb}user@{endsb}host.xz/~user/path/to/repo.git/
  15- ssh://{startsb}user@{endsb}host.xz/~/path/to/repo.git
  16===============================================================
  17
  18SSH is the default transport protocol.  You can optionally specify
  19which user to log-in as, and an alternate, scp-like syntax is also
  20supported.  Both syntaxes support username expansion,
  21as does the native git protocol. The following three are
  22identical to the last three above, respectively:
  23
  24===============================================================
  25- {startsb}user@{endsb}host.xz:/path/to/repo.git/
  26- {startsb}user@{endsb}host.xz:~user/path/to/repo.git/
  27- {startsb}user@{endsb}host.xz:path/to/repo.git
  28===============================================================
  29
  30To sync with a local directory, use:
  31
  32===============================================================
  33- /path/to/repo.git/
  34===============================================================
  35
  36REMOTES
  37-------
  38
  39In addition to the above, as a short-hand, the name of a
  40file in `$GIT_DIR/remotes` directory can be given; the
  41named file should be in the following format:
  42
  43        URL: one of the above URL format
  44        Push: <refspec>
  45        Pull: <refspec>
  46
  47Then such a short-hand is specified in place of
  48<repository> without <refspec> parameters on the command
  49line, <refspec> specified on `Push:` lines or `Pull:`
  50lines are used for `git-push` and `git-fetch`/`git-pull`,
  51respectively.  Multiple `Push:` and `Pull:` lines may
  52be specified for additional branch mappings.
  53
  54Or, equivalently, in the `$GIT_DIR/config` (note the use
  55of `fetch` instead of `Pull:`):
  56
  57[remote "<remote>"]
  58        url = <url>
  59        push = <refspec>
  60        fetch = <refspec>
  61
  62The name of a file in `$GIT_DIR/branches` directory can be
  63specified as an older notation short-hand; the named
  64file should contain a single line, a URL in one of the
  65above formats, optionally followed by a hash `#` and the
  66name of remote head (URL fragment notation).
  67`$GIT_DIR/branches/<remote>` file that stores a <url>
  68without the fragment is equivalent to have this in the
  69corresponding file in the `$GIT_DIR/remotes/` directory.
  70
  71        URL: <url>
  72        Pull: refs/heads/master:<remote>
  73
  74while having `<url>#<head>` is equivalent to
  75
  76        URL: <url>
  77        Pull: refs/heads/<head>:<remote>