Skip to content

Commit

Permalink
Documentation/urls.txt: Use substitution to escape square brackets
Browse files Browse the repository at this point in the history
This changes "[user@]" to use {startsb} and {endsb} to insert [ and ],
similar to how {caret} is used in git-rev-parse.txt.

[jc: Removed a well-intentioned comment that broke the final
 formatting from the original patch.  While we are at it,
 updated the paragraph that claims to be equivalent to the
 section that was updated earlier without making matching
 changes.]

Signed-off-by: Jonas Fonseca <fonseca@diku.dk>
Signed-off-by: Junio C Hamano <junkio@cox.net>
  • Loading branch information
Jonas Fonseca authored and Junio C Hamano committed Jul 14, 2006
1 parent c7543ce commit a3e65d7
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 8 deletions.
2 changes: 2 additions & 0 deletions Documentation/asciidoc.conf
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@

[attributes]
caret=^
startsb=&#91;
endsb=&#93;

ifdef::backend-docbook[]
[gitlink-inlinemacro]
Expand Down
17 changes: 9 additions & 8 deletions Documentation/urls.txt
Original file line number Diff line number Diff line change
Expand Up @@ -10,20 +10,21 @@ to name the remote repository:
- https://host.xz/path/to/repo.git/
- git://host.xz/path/to/repo.git/
- git://host.xz/~user/path/to/repo.git/
- ssh://+++[user@+++]host.xz/path/to/repo.git/
- ssh://+++[user@+++]host.xz/~user/path/to/repo.git/
- ssh://+++[user@+++]host.xz/~/path/to/repo.git
- ssh://{startsb}user@{endsb}host.xz/path/to/repo.git/
- ssh://{startsb}user@{endsb}host.xz/~user/path/to/repo.git/
- ssh://{startsb}user@{endsb}host.xz/~/path/to/repo.git
===============================================================

SSH is the default transport protocol and also supports an
scp-like syntax. Both syntaxes support username expansion,
SSH is the default transport protocol. You can optionally specify
which user to log-in as, and an alternate, scp-like syntax is also
supported. Both syntaxes support username expansion,
as does the native git protocol. The following three are
identical to the last three above, respectively:

===============================================================
- host.xz:/path/to/repo.git/
- host.xz:~user/path/to/repo.git/
- host.xz:path/to/repo.git
- {startsb}user@{endsb}host.xz:/path/to/repo.git/
- {startsb}user@{endsb}host.xz:~user/path/to/repo.git/
- {startsb}user@{endsb}host.xz:path/to/repo.git
===============================================================

To sync with a local directory, use:
Expand Down

0 comments on commit a3e65d7

Please sign in to comment.