Fixed some small mistakes in relation to handling of git-config settings.
This commit is contained in:
parent
a05403df60
commit
109fefb978
|
@ -36,9 +36,9 @@ def __read_git_config__(run, variable, destination=None):
|
||||||
setting = setting.decode("utf-8", "replace").strip()
|
setting = setting.decode("utf-8", "replace").strip()
|
||||||
|
|
||||||
if setting == "True" or setting == "true" or setting == "t" or setting == "1":
|
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":
|
elif setting == "False" or setting == "false" or setting == "f" or setting == "0":
|
||||||
run.opts[destination] = False
|
vars(run.opts)[destination] = False
|
||||||
return True
|
return True
|
||||||
|
|
||||||
except IndexError:
|
except IndexError:
|
||||||
|
|
|
@ -145,6 +145,8 @@ def main():
|
||||||
#We need the repo above to be set before we read the git config.
|
#We need the repo above to be set before we read the git config.
|
||||||
config.init(__run__)
|
config.init(__run__)
|
||||||
|
|
||||||
|
parser.parse_args(values=opts)
|
||||||
|
|
||||||
except (format.InvalidFormatError, optval.InvalidOptionArgument, optval.OptionParsingError) as msg:
|
except (format.InvalidFormatError, optval.InvalidOptionArgument, optval.OptionParsingError) as msg:
|
||||||
print(sys.argv[0], "\b:", end=" ")
|
print(sys.argv[0], "\b:", end=" ")
|
||||||
print(msg)
|
print(msg)
|
||||||
|
|
Loading…
Reference in New Issue