Re: [PATCH 1/6] gitopt: a new command-line option parser for git

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

 



Junio C Hamano <junkio@xxxxxxx> wrote:

> Timo Hirvonen <tihirvon@xxxxxxxxx> writes:
> 
> > I think optional arguments are still confusing.  We could support both
> > -C (no args) and -C=20 syntax.
> 
> Actually, optional numeric arguments are the norm not exception.
> Think of "diff -u" vs "diff -u20" for example.  Also I think it
> is conventional not to use = for single-letter single-dash
> options, so -C (no args -- use the default number of the
> implementation whatever it is) and -C20 (the same behaviour in
> principle as -C, but use my number instead of the default) are
> sane, while -C=20 _is_ odd.

OK, if we don't support bundling flags at all then -x=y and -xy would do
the same thing and pickaxe's -Stext would work too.  But we could not
make option flag parsing global then (-S=value -> search "=value" or
"value"?).

Maybe we should just change -Stext to -S=text or -S text.

Better to support only -x=y or -x y, not both.

> Having said that, I think abbreviating -u20 -n -r to -u20nr
> going too far

Yes

> (-nru20 would be palatable perhaps),

No :)

-- 
http://onion.dynserv.net/~timo/
-
: 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]