diff --git a/gitinspector/config.py b/gitinspector/config.py index ad5f8af..0206b70 100644 --- a/gitinspector/config.py +++ b/gitinspector/config.py @@ -36,9 +36,9 @@ def __read_git_config__(run, variable, destination=None): setting = setting.decode("utf-8", "replace").strip() if setting == "True" or setting == "true" or setting == "t" or setting == "1": - run.opts[destination] = True + vars(run.opts)[destination] = True elif setting == "False" or setting == "false" or setting == "f" or setting == "0": - run.opts[destination] = False + vars(run.opts)[destination] = False return True except IndexError: diff --git a/gitinspector/gitinspector.py b/gitinspector/gitinspector.py index af9b150..a3e70f7 100755 --- a/gitinspector/gitinspector.py +++ b/gitinspector/gitinspector.py @@ -145,6 +145,8 @@ def main(): #We need the repo above to be set before we read the git config. config.init(__run__) + parser.parse_args(values=opts) + except (format.InvalidFormatError, optval.InvalidOptionArgument, optval.OptionParsingError) as msg: print(sys.argv[0], "\b:", end=" ") print(msg)