style-improvements at cmdline-arg-parsing

This commit is contained in:
Thor77 2015-07-13 20:54:59 +02:00
parent 9a1ed27ba2
commit ffabb9c284
1 changed files with 2 additions and 4 deletions

View File

@ -227,10 +227,8 @@ def parse_config(config_path):
def main(): def main():
# check cmdline-args # check cmdline-args
config_path = argv[1] if len(argv) >= 2 else 'config.ini' config_path = abspath + (argv[1] if len(argv) >= 2 else 'config.ini')
config_path = abspath + config_path id_map_path = abspath + (argv[2] if len(argv) >= 3 else 'id_map.json')
id_map_path = argv[2] if len(argv) >= 3 else 'id_map.json'
id_map_path = abspath + id_map_path
if not exists(config_path): if not exists(config_path):
raise Exception('Couldn\'t find config-file at {}'.format(config_path)) raise Exception('Couldn\'t find config-file at {}'.format(config_path))