Review Request 115332: Add a --quiet option
Alex Merry
kde at randomguy3.me.uk
Mon Jan 27 17:51:46 UTC 2014
> On Jan. 27, 2014, 5:37 p.m., Aurélien Gâteau wrote:
> > Looks good, but I would suggest using Python logging module instead of writing our own. Basic usage should be as simple as:
> >
> > # setup
> > import logging
> >
> > ... parse args...
> >
> > if args.quiet:
> > minlevel = logging.WARNING
> > else:
> > minlevel = logging.INFO
> >
> > logging.basicConfig(level=minlevel, format='%(asctime)s:%(levelname)s: %(message)s')
> >
> > # then use it like this
> > logging.info("Foo")
> > logging.error("Something went wrong!")
Ah, I should probably have guessed that Python would have something like that built-in :-)
- Alex
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/115332/#review48402
-----------------------------------------------------------
On Jan. 27, 2014, 4:25 p.m., Alex Merry wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://git.reviewboard.kde.org/r/115332/
> -----------------------------------------------------------
>
> (Updated Jan. 27, 2014, 4:25 p.m.)
>
>
> Review request for KDE Frameworks and Aurélien Gâteau.
>
>
> Repository: kapidox
>
>
> Description
> -------
>
> Add a --quiet option
>
>
> Diffs
> -----
>
> src/kgenapidox eadd3a77b42b92df882456fa25c20339d4394708
> src/kapidox/__init__.py c89e06fdc2385f07b074b14574c1e62900723cab
> src/kgenframeworksapidox f565eb36fb0dc952643ff174001c5ee6f96cd394
>
> Diff: https://git.reviewboard.kde.org/r/115332/diff/
>
>
> Testing
> -------
>
> Built some dox (Python 2.7, I think).
>
>
> Thanks,
>
> Alex Merry
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20140127/a3a03864/attachment.html>
More information about the Kde-frameworks-devel
mailing list