Re: [PATCH] upload-pack.c: use of parse-options API

2016-05-19 Thread Matthieu Moy
Jeff King wrote: > On Thu, May 19, 2016 at 12:10:31PM +0200, Antoine Queru wrote: > > > > I'm not sure whether it is worth hiding the first two options. We > > > typically hide "internal" options like this for user-facing programs, so > > > as not to clutter the "-h" output. But upload-pack isn't

Re: [PATCH] upload-pack.c: use of parse-options API

2016-05-19 Thread Jeff King
On Thu, May 19, 2016 at 12:10:31PM +0200, Antoine Queru wrote: > > I'm not sure whether it is worth hiding the first two options. We > > typically hide "internal" options like this for user-facing programs, so > > as not to clutter the "-h" output. But upload-pack isn't a user-facing > > program.

Re: [PATCH] upload-pack.c: use of parse-options API

2016-05-19 Thread Antoine Queru
Thanks for your input. > > -static const char upload_pack_usage[] = "git upload-pack [--strict] > > [--timeout=] "; > > +static const char * const upload_pack_usage[] = { > > + N_("git upload-pack [--strict] [--timeout=] "), > > + NULL > > +}; > > Do we need to enumerate the options here

Re: [PATCH] upload-pack.c: use of parse-options API

2016-05-18 Thread Jeff King
On Wed, May 18, 2016 at 06:40:19PM +0200, Antoine Queru wrote: > Option parsing now uses the parser API instead of a local parser. > Code is now more compact. Sounds like a good goal. > -static const char upload_pack_usage[] = "git upload-pack [--strict] > [--timeout=] "; > +static const char