[RFC] [PATCH] configurable selection of progress indicator
Robert Collins
robertc at robertcollins.net
Thu Dec 15 08:03:57 GMT 2005
On Thu, 2005-12-15 at 00:57 +0100, duchier at ps.uni-sb.de wrote:
> The attached patch makes it possible to select the type of progress
> indicator (either using dots or a progress bar).
>
> all commands now accept:
>
> --progress=dot
> --progress=bar
>
> and the [DEFAULT] section of ~/.bazaar/bazaar.conf may also contain
>
> progress=dot
> or progress=bar
>
> The selection logic is:
>
> 1. if we don't have a tty, use dots
> 2. else obey a command-line option
> 3. else obey a config option
> 4. else if this is a dumb terminal use dots
> 5. otherwise use a progress bar
>
> I chose "progress" because that is also what "wget" calls it. I would
> prefer for "progress" to be a global option rather than a command
> option, but there is at present no convenient support for global
> options.
There are several global options at the moment - whats wrong with
hooking into that?
-1 at the moment:
- no tests
- the introduction of global symbols in config.py doesn't fit the other
idioms in there. I think what you want is a global option - please use
the existing infrastructure for that. (Yes, that infrastructure needs
refactoring to reduce duplication, muddying the waters won't help
though).
+1 in concept though.
I dont really care about environment vs global option, but I do agree
with fullmd's concern about having 4 billion env variables. If we go for
an environment variable though, perhaps we should have one that is
parsed for global options - thus preventing variable count expansion.
Rob
--
GPG key available at: <http://www.robertcollins.net/keys.txt>.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20051215/1d8a0e21/attachment.pgp
More information about the bazaar
mailing list