git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: Documentation/user-manual.txt, asciidoc and "--" escapes

From
Jonas Fonseca <fonseca@diku.dk>
Date
Nov 9, 2008, 18:52 UTC
Message-ID
<2c6b72b30811091052k77200785j722c8aed2beb7684@mail.gmail.com>
In-Reply-To
<ddb82bf60811090044l43eb4bb1ga5a16718a4176c29@mail.gmail.com>
> On Fri, Nov 7, 2008 at 04:09, Piotr Findeisen <piotr.findeisen@gmail.com> wrote:
>> Hello!
Hello,
>> The attached file is a result of running `git diff HEAD~1`.

Please read Documentation/SubmittingPatches for the preferred way to contribute patches.

>> Asciidoc replaces "--" with "—" when not in verbatim mode. This is
>> sometimes unwanted -- especially when citing command line options like
>> "git diff --cached". This commit includes proper quotes in user-manual.txt.

Newer asciidoc versions have the following "workaround". Maybe adding something like this to Documentation/asciidoc.conf would be more future proof.

# -- Spaced and unspaced em dashes (entity reference &mdash;) # But disallow unspaced in man pages because double-dash option name prefixes # are pervasive. ifndef::doctype-manpage[] (^|[^-\\])--($|[^-])=\1&#8212;\2 endif::doctype-manpage[] ifdef::doctype-manpage[] (^|\s*[^\S\\])--($|\s+)=\1&#8212;\2 endif::doctype-manpage[] \\--(?!-)=--

-- 
Jonas Fonseca
Previous: Piotr FindeisenNext: Piotr Findeisen
Message 3 of 9 in “Fwd: Documentation/user-manual.txt, asciidoc and "--" escapes”
  1. Piotr FindeisenNov 7, 2008
  2. Piotr FindeisenNov 9, 2008
  3. Jonas FonsecaNov 9, 2008
  4. Piotr FindeisenNov 10, 2008
  5. Jonas FonsecaNov 10, 2008
  6. Piotr FindeisenNov 10, 2008
  7. Jonas FonsecaNov 12, 2008
  8. Piotr FindeisenNov 14, 2008
  9. Junio C HamanoNov 15, 2008

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.