Re: [PATCH v3 19/36] doc txt & -h consistency: add or fix optional "--" syntax

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Ævar Arnfjörð Bjarmason  <avarab@xxxxxxxxx> writes:

> diff --git a/builtin/rev-list.c b/builtin/rev-list.c
> index ada68a4af5e..3cc8aad52ed 100644
> --- a/builtin/rev-list.c
> +++ b/builtin/rev-list.c
> @@ -20,7 +20,7 @@
>  #include "packfile.h"
>  
>  static const char rev_list_usage[] =
> -"git rev-list [<options>] <commit>... [-- <path>...]\n"
> +"git rev-list [<options>] <commit>... [[--] <path>...]\n"

As rev-list requires at least one commit, so <commit>... means one
or more of <commit>.  Now rev-list does not have to have pathspec,
but it is OK to have the double-dash, so

    git rev-list [<options>] <commit>... [--] [<path>...]

would be more correct, no?  <path>... may mean one or more pathspec
elements, but having it inside [] makes it zero or more.  But it is
not a crime to have "--" without any pathspec, yet [[--] <path>...]
requires one or more paths if you want to write "--".





[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux