[MERGE] Commit less verbose
Ian Clatworthy
ian.clatworthy at internode.on.net
Mon Sep 3 15:01:49 BST 2007
Attached is the patch for making commit less verbose. This has been
simplified somewhat from the previous submission because of the new
standard options feature now integrated.
I've retested the performance impact and it's still around 15% as an
improvement on the initial commit of a Python 2.5 tree (~3700 files).
Aaron Bentley wrote:
> Ian Clatworthy wrote:
>> This was discussed some time back here:
>> https://lists.ubuntu.com/archives/bazaar/2007q2/027044.html. As that
>> thread indicates, everyone who voiced an opinion agreed at the time.
>> Let's hope everyone still does. :-) (If not, you can always add an alias
>> for commit that switches --verbose back on by default.)
>
>> Running some profiling today, I noticed that 15% of an initial commit on
>> a Python tree (3726 files) was generating output even when output was
>> redirected to /dev/null. The attached patch implements the multiple
>> noise levels improvement and delivers better performance by using that
>> level information to skip generating info if we know we're never going
>> to display it.
> a) --quiet already has a meaning in the codebase. I don't think it
> makes sense to reuse it. Also, does it work with aliases?
>
> b) "bzr commit --quiet --verbose" should select "verbose", the way the
> rest of our options behave.
These issues have been covered in a separate patch now merged.
>> @@ -728,7 +758,8 @@
>> if ie is not None:
>> self.builder.record_entry_contents(ie, self.parent_invs,
>> path, self.work_tree)
>> - self._report_change(ie, path)
>> + if self.reporter.is_verbose():
>> + self._report_change(ie, path)
>
> ^^^ is this really a win? You don't have newer function calls. You may
> have *more*, in fact.
Fixed.
Ian C.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: commit-less-verbose.patch
Type: text/x-patch
Size: 21395 bytes
Desc: not available
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20070904/45756f72/attachment-0001.bin
More information about the bazaar
mailing list