Don't show INFO: when not doing verbose runs

This commit is contained in:
Daniel Martí 2014-02-09 12:39:43 +01:00
parent ec0de6b370
commit d949b9ffbb

8
fdroid
View file

@ -58,8 +58,12 @@ def main():
verbose = any(s in sys.argv for s in ['-v', '--verbose']) verbose = any(s in sys.argv for s in ['-v', '--verbose'])
logging.basicConfig(format='%(levelname)s: %(message)s', if verbose:
level=logging.DEBUG if verbose else logging.INFO) logging.basicConfig(format='%(levelname)s: %(message)s',
level=logging.DEBUG)
else:
logging.basicConfig(format='%(message)s',
level=logging.INFO)
# Trick optparse into displaying the right usage when --help is used. # Trick optparse into displaying the right usage when --help is used.
sys.argv[0] += ' ' + command sys.argv[0] += ' ' + command