git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: "Jean-Noël AVILA" <jn.avila@free.fr>
To: "Martin Ågren" <martin.agren@gmail.com>,
	"Junio C Hamano" <gitster@pobox.com>
Cc: "Jean-Noël Avila via GitGitGadget" <gitgitgadget@gmail.com>,
	git@vger.kernel.org
Subject: Re: [PATCH 4/4] doc: git-clone: apply new documentation guidelines
Date: Tue, 26 Mar 2024 21:49:17 +0100	[thread overview]
Message-ID: <3285532.aeNJFYEL58@cayenne> (raw)
In-Reply-To: <xmqq8r24agov.fsf@gitster.g>

On Tuesday, 26 March 2024 21:20:16 CET Junio C Hamano wrote:
> Martin Ågren <martin.agren@gmail.com> writes:
> 
> >> +`git clone` [`--template=`{empty}__<template-directory>__]
> >> +         [`-l`] [`-s`] [`--no-hardlinks`] [`-q`] [`-n`] [`--bare`] [`--
mirror`]
> >> +         [`-o` _<name>_] [`-b` _<name>_] [`-u` _<upload-pack>_] [`--
reference` _<repository>_]
> >> +         [`--dissociate`] [`--separate-git-dir` _<git-dir>_]
> >> +         [`--depth` _<depth>_] [`--`[`no-`]`single-branch`] [`--no-
tags`]
> >> +         [`--recurse-submodules`[`=`{empty}__<pathspec>__]] [`--`[`no-
`]`shallow-submodules`]
> >> +         [`--`[`no-`]`remote-submodules`] [`--jobs` _<n>_] [`--sparse`] 
[`--`[`no-`]`reject-shallow`]
> >> +         [`--filter=`{empty}__<filter-spec>__] [`--also-filter-
submodules`]] [`--`] _<repository>_
> >> +         [_<directory>_]
> >
> > Don't ask me why, but I need this on top (whitespace-damaged)
> >
> > -         [`--depth` _<depth>_] [`--`[`no-`]`single-branch`] [`--no-tags`]
> > -         [`--recurse-submodules`[`=`{empty}__<pathspec>__]]
> > [`--`[`no-`]`shallow-submodules`]
> > -         [`--`[`no-`]`remote-submodules`] [`--jobs` _<n>_]
> > [`--sparse`] [`--`[`no-`]`reject-shallow`]
> > +         [`--depth` _<depth>_] [`--`[`no-`]{empty}`single-branch`]
> > [`--no-tags`]
> > +         [`--recurse-submodules`[`=`{empty}__<pathspec>__]]
> > [`--`[`no-`]{empty}`shallow-submodules`]
> > +         [`--`[`no-`]{empty}`remote-submodules`] [`--jobs` _<n>_]
> > [`--sparse`] [`--`[`no-`]{empty}`reject-shallow`]
> >
> > i.e., some sprinkling of "{empty}", to keep each of these "[--[no-]"
> > from simply disappearing. This is with Asciidoctor 1.5.5, which is
> > admittedly starting to get old, but still ok as per our INSTALL
> > document.
> 
> The original from Jean-Noël was already bad enough with all these
> {empty}, but now this is even worse.

I must concede this does not help make these parts readable in the source.
The point that Martin raised is the worst for me: if the processing of this 
workaround is depend on the version of Asciidoc[tor], the way of writing this 
formatting for stuck parts in a compatible way must be clearly defined (and 
made understandable).


> 
> >> ---bare::
> >> +`--bare`::
> >>         Make a 'bare' Git repository.  That is, instead of
> >>         creating _<directory>_ and placing the administrative
> >> -       files in `<directory>/.git`, make the _<directory>_
> >> +       files in _<directory>_`/.git`, make the _<directory>_
> >
> > This should be __<directory>__{empty}`/.git`
> 
> The worst part is that I am not sure if there is a pattern easily
> understandable by document writers to help them decide where to
> sprinkle these {empty} mark-ups.  Of course, they are visually very
> distracting and made our documentation that used to be perfectly
> readable in the source form to something much less pleasant to read.
> 
> Can we make both the rendered output nicer while keeping the source
> still readable and easy to maintain?
> 
> Thanks.
> 

I came up with this trickery because of the use of "legacy" Asciidoc format, 
which does not understand unconstrained formatting (doubling the signs, so 
that they don't care about word boundary). With the new format, we would 
simply write:

__<directory>__``/.git``
``--filter=``__<filter-spec>__

Without having to pay attention to the surrounding characters.

For now, we are stuck with the compatibility with the existing tools. I will 
try an propose something else. Would preprocessing be accepted?






  reply	other threads:[~2024-03-26 20:49 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-03-24 22:18 [PATCH 0/4] Doc new guidelines Jean-Noël Avila via GitGitGadget
2024-03-24 22:18 ` [PATCH 1/4] doc: rework CodingGuidelines with new formatting rules Jean-Noël Avila via GitGitGadget
2024-03-24 22:18 ` [PATCH 2/4] doc: allow literal and emphasis format in doc vs help tests Jean-Noël Avila via GitGitGadget
2024-03-28 10:06   ` Jeff King
2024-03-28 10:21     ` Eric Sunshine
2024-03-24 22:18 ` [PATCH 3/4] doc: git-init: apply new documentation formatting guidelines Jean-Noël Avila via GitGitGadget
2024-03-26 20:18   ` Martin Ågren
2024-03-26 20:26     ` Jean-Noël AVILA
2024-03-24 22:18 ` [PATCH 4/4] doc: git-clone: apply new documentation guidelines Jean-Noël Avila via GitGitGadget
2024-03-26 20:03   ` Martin Ågren
2024-03-26 20:20     ` Junio C Hamano
2024-03-26 20:49       ` Jean-Noël AVILA [this message]
2024-03-26 20:59         ` Junio C Hamano
2024-03-29 11:19 ` [PATCH v2 0/5] Doc new guidelines Jean-Noël Avila via GitGitGadget
2024-03-29 11:19   ` [PATCH v2 1/5] doc: rework CodingGuidelines with new formatting rules Jean-Noël Avila via GitGitGadget
2024-03-29 18:42     ` Eric Sunshine
2024-03-30 17:36       ` Jean-Noël AVILA
2024-03-29 11:19   ` [PATCH v2 2/5] doc: allow literal and emphasis format in doc vs help tests Jean-Noël Avila via GitGitGadget
2024-03-29 11:19   ` [PATCH v2 3/5] doc: git-init: apply new documentation formatting guidelines Jean-Noël Avila via GitGitGadget
2024-03-29 11:19   ` [PATCH v2 4/5] doc: git-clone: " Jean-Noël Avila via GitGitGadget
2024-03-29 11:19   ` [PATCH v2 5/5] doc: git-clone: do not autoreference the manpage in itself Jean-Noël Avila via GitGitGadget

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3285532.aeNJFYEL58@cayenne \
    --to=jn.avila@free.fr \
    --cc=git@vger.kernel.org \
    --cc=gitgitgadget@gmail.com \
    --cc=gitster@pobox.com \
    --cc=martin.agren@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).