Re: [PATCH] urls.txt: Use substitution to escape square brackets

2 messages, 2 authors, 2016-06-15 · open the first message on its own page

Re: [PATCH] urls.txt: Use substitution to escape square brackets

From: Junio C Hamano <hidden>
Date: 2016-06-15 22:42:33

Jonas Fonseca [off-list ref] writes:
This changes "[user@]" to use {startsb} and {endsb} to insert [ and ],
similar to how {caret} is used in git-rev-parse.txt.

Signed-off-by: Jonas Fonseca <redacted>
Looks nicer.  Alp?  Does this work with your version of
asciidoc?

Re: [PATCH] urls.txt: Use substitution to escape square brackets

From: Alp Toker <hidden>
Date: 2016-06-15 22:42:33

Junio C Hamano wrote:
Jonas Fonseca [off-list ref] writes:
quoted
This changes "[user@]" to use {startsb} and {endsb} to insert [ and ],
similar to how {caret} is used in git-rev-parse.txt.

Signed-off-by: Jonas Fonseca <redacted>
Looks nicer.  Alp?  Does this work with your version of
asciidoc?
I'm using asciidoc 7.0.2, which came with Ubuntu Dapper.

The man page output now looks like this:

        ·  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

Still not correct.

Out of the three patches,

   (at) "ssh://[user@]host.xz/path/to/repo.git/"
   (jc) "ssh://+++[user@+++]host.xz/path/to/repo.git/"
   (jf) "ssh://{startsb}user@{endsb}host.xz/path/to/repo.git/"

I'd say (at) is still most readable, not requiring +++ markup (jc) or 
hacks to asciidoc.conf (jf). And it's the only fix that's compatible 
with older versions.

That's unless I've missed out on some detail that makes (at) unworkable. 
  If it's the dozen or so modified lines that are a problem, we can work 
on a wdiff merge strategy or something in the time we save looking for 
the asciidoc escape sequence that works for everyone. Junio?
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help