Skip to content

Commit

Permalink
Previously there was only logging output when the --debug flag was
Browse files Browse the repository at this point in the history
present.  I changed it so that the warn and error messages will still
be output even if the --debug is not present.
  • Loading branch information
jsf9k committed Nov 28, 2017
1 parent 0b4f634 commit 8173729
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions trustymail/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,10 @@
"""
from trustymail import __version__

import logging
import docopt
import os
import errno
import logging
import os

from trustymail import trustymail

Expand All @@ -51,8 +51,10 @@
def main():
args = docopt.docopt(__doc__, version=__version__)

log_level = logging.WARN
if args['--debug']:
logging.basicConfig(format='%(message)s', level=logging.DEBUG)
log_level = logging.DEBUG
logging.basicConfig(format='%(asctime)-15s %(message)s', level=log_level)

# Allow for user to input a csv for many domain names.
if args['INPUT'][0].endswith('.csv'):
Expand Down

0 comments on commit 8173729

Please sign in to comment.