git@vger.kernel.org list mirror (unofficial, one of many)
 help / color / mirror / code / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: "Ævar Arnfjörð Bjarmason" <avarab@gmail.com>
Cc: Adam Spiers <git@adamspiers.org>, git mailing list <git@vger.kernel.org>
Subject: Re: git-log: documenting pathspec usage
Date: Mon, 16 Nov 2020 10:55:40 -0800	[thread overview]
Message-ID: <xmqqblfx9ln7.fsf@gitster.c.googlers.com> (raw)
In-Reply-To: <878sb1fpep.fsf@evledraar.gmail.com> (=?utf-8?B?IsOGdmFyIEFy?= =?utf-8?B?bmZqw7Zyw7A=?= Bjarmason"'s message of "Mon, 16 Nov 2020 13:37:50 +0100")

Ævar Arnfjörð Bjarmason <avarab@gmail.com> writes:

> It seems like a good idea to make these consistent, if you're feeling
> more ambitious than just git-log's manpage then:
>     
>     $ git grep '<pathspec>' -- Documentation/git-*.txt|wc -l
>     54
>     $ git grep '<path>' -- Documentation/git-*.txt|wc -l
>     161
>
> Most/all of these should probably be changed to one or the other.

There is another thing we want to normalize.

Originally <pathspec> was invented to be a collective noun (i.e. a
set of one or more wildmatch patterns that specify paths that match
any of these patterns is called a pathspec).  These days, however,
we more often refer to each individual pattern as <pathspec> than
using the word in its original way.  We can look for '<pathspec>...'
in the documentation to find these more modern usage.

This latter form would match readers' expectation better, but there
still are a few places (e.g. "stash forget <pathspec>") that use the
word as a collection of pattterns.  While these places may be using
the word "correctly", in the modern world, they give an incorrect
impression that the command somehow is special and can take a
pathspec with only a single pattern, when they can take one or more
patterns.

We should make sure we use "<pathspec>..."  uniformly in the
documentation in these places.

Thanks.


      parent reply	other threads:[~2020-11-16 18:57 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-11-16 12:22 Adam Spiers
2020-11-16 12:37 ` Ævar Arnfjörð Bjarmason
2020-11-16 17:46   ` Philippe Blain
2020-11-16 18:55   ` Junio C Hamano [this message]

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=xmqqblfx9ln7.fsf@gitster.c.googlers.com \
    --to=gitster@pobox.com \
    --cc=avarab@gmail.com \
    --cc=git@adamspiers.org \
    --cc=git@vger.kernel.org \
    --subject='Re: git-log: documenting pathspec usage' \
    /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

Code repositories for project(s) associated with this 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).