Re: [RFC/PATCH 0/4] update-index: migrate to parse-options API

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

 



Jonathan Nieder <jrnieder@xxxxxxxxx> writes:

> Jonathan Nieder wrote:
>
>> Here's a helper to make it easier for commands that use parse-options
>> to adopt that nicer behavior.  It writes its output to stdout, so it
>> should only be used to be used to handle the -h option.
>
> Alas, "git update-index" does not use parse-options yet.  But that
> is easily enough changed...
>
> Patch 1 introduces an OPTION_LOWLEVEL_CALLBACK backdoor to
> parse-options, so new option types (like the three-argument type
> used by update-index --cacheinfo) can be supported without tempting
> inventors of other commands through mention in the public API.

I like the idea of this one.  I imagine it can also be used to finally
whip the command line parsing of "log -L" series Thomas mentored into a
reasonable shape, which needs to parse the -L option that takes <range>
and an optional <path> (not <pathspec>) as arguments.
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[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]