[MERGE] Add --no-pending to status to not show the pending merges. (#202830)
James Westby
jw+debian at jameswestby.net
Mon Mar 17 00:04:48 GMT 2008
On Sun, 2008-03-16 at 18:39 +0000, John Arbash Meinel wrote:
> Actually if you do:
>
> def run(pending=True):
>
> It at least *used* to have the option on as default. That may have
> changed with the optparse changes. I don't know if it always sets all
> "takes_options" or if it continues the habit of only passing an entry in
> **kwargs that was actually set by the user.
I've been wondering this for a while, but never bothered to test it out.
What I would like it for is so that the user can override a value from
a config file in builddeb to be the default of the command line option.
Specifically, with a boolean flag --foo, default false, and a config
option foo, if the user has
foo = True
then if I have
run(foo=False)
then they can't override it, as I have to do
if not foo:
get_from_config(foo)
but if I can do
run(foo=None)
I can have
if foo is None:
instead, and they can do --no-foo to override the config temporarily.
I'll experiment tomorrow, but I would definitely like this feature,
for reasons over and above the aesthetic reasons John gave.
>
> The big thing is that I find dealing in negatives to be ugly, and the
> fact that the first thing he does is:
>
> pending=not no_pending
>
> Signifies some agreement.
I agree that it is ugly, and so I will look for an easy way to change
it.
Thanks,
James
More information about the bazaar
mailing list