diff mbox series

git config doc: fix recent ASCIIDOC formatting regresison

Message ID patch-1.1-36700e581d2-20211019T123057Z-avarab@gmail.com (mailing list archive)
State Accepted
Commit 4da10a5162866336fbba34f4f78604a20aed7bdd
Headers show
Series git config doc: fix recent ASCIIDOC formatting regresison | expand

Commit Message

Ævar Arnfjörð Bjarmason Oct. 19, 2021, 12:31 p.m. UTC
Fix a regression in 8c328561332 (blame: document --color-* options,
2021-10-08), which added an extra newline before the "+" syntax.

The "Documentation/doc-diff HEAD~ HEAD" output with this applied is:

    [...]
    @@ -1815,13 +1815,13 @@ CONFIGURATION FILE
                specified colors if the line was introduced before the given
                timestamp, overwriting older timestamped colors.

    -       + Instead of an absolute timestamp relative timestamps work as well,
    -       e.g. 2.weeks.ago is valid to address anything older than 2 weeks.
    +           Instead of an absolute timestamp relative timestamps work as well,
    +           e.g.  2.weeks.ago is valid to address anything older than 2 weeks.

    -       + It defaults to blue,12 month ago,white,1 month ago,red, which colors
    -       everything older than one year blue, recent changes between one month
    -       and one year old are kept white, and lines introduced within the last
    -       month are colored red.
    +           It defaults to blue,12 month ago,white,1 month ago,red, which
    +           colors everything older than one year blue, recent changes between
    +           one month and one year old are kept white, and lines introduced
    +           within the last month are colored red.

            color.blame.repeatedLines
                Use the specified color to colorize line annotations for git blame

Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
---
 Documentation/config/color.txt | 2 --
 1 file changed, 2 deletions(-)

Comments

Jeff King Oct. 19, 2021, 9:11 p.m. UTC | #1
On Tue, Oct 19, 2021 at 02:31:34PM +0200, Ævar Arnfjörð Bjarmason wrote:

> Fix a regression in 8c328561332 (blame: document --color-* options,
> 2021-10-08), which added an extra newline before the "+" syntax.

Thanks, this looks like an obviously correct fix. I think asciidoc's
pickiness around "+" has bitten us before. Asciidoctor is more lenient
here, and the rendered result looks the same before and after your
patch, but we should definitely make it look good in both.

> The "Documentation/doc-diff HEAD~ HEAD" output with this applied is:

I just want to call this out not only as a good way to review this
patch, but a great way in general to review any patches which touch
documentation. Running:

  doc-diff 8c328561332^ 8c328561332

shows the original problem pretty clearly.

>  Documentation/config/color.txt | 2 --
>  1 file changed, 2 deletions(-)

Patch looks good. There's a small typo in the subject:

> Subject: [PATCH] git config doc: fix recent ASCIIDOC formatting regresison

s/regresison/regression/

-Peff
Junio C Hamano Oct. 20, 2021, 3:35 p.m. UTC | #2
Jeff King <peff@peff.net> writes:

> I just want to call this out not only as a good way to review this
> patch, but a great way in general to review any patches which touch
> documentation. Running:
>
>   doc-diff 8c328561332^ 8c328561332
>
> shows the original problem pretty clearly.

I actually was somewhat miffed to see that this did not help an
update being discussed on MyFirstContribution X-<.  It could have
been a driver error, though.

>>  Documentation/config/color.txt | 2 --
>>  1 file changed, 2 deletions(-)
>
> Patch looks good. There's a small typo in the subject:
>
>> Subject: [PATCH] git config doc: fix recent ASCIIDOC formatting regresison
>
> s/regresison/regression/

Thanks.
diff mbox series

Patch

diff --git a/Documentation/config/color.txt b/Documentation/config/color.txt
index dd2d2e0d84e..6e817f60476 100644
--- a/Documentation/config/color.txt
+++ b/Documentation/config/color.txt
@@ -17,11 +17,9 @@  date settings, starting and ending with a color, the dates should be
 set from oldest to newest. The metadata will be colored with the
 specified colors if the line was introduced before the given
 timestamp, overwriting older timestamped colors.
-
 +
 Instead of an absolute timestamp relative timestamps work as well,
 e.g. `2.weeks.ago` is valid to address anything older than 2 weeks.
-
 +
 It defaults to `blue,12 month ago,white,1 month ago,red`, which
 colors everything older than one year blue, recent changes between