From b47092093ee1b390de60e5cae8021286874c6d48 Mon Sep 17 00:00:00 2001 From: Grigori Goronzy Date: Wed, 27 Jun 2018 01:03:22 +0200 Subject: [PATCH] Fix frontend argument parser Refactoring sneaked in an issue with the string formatting. --- stcgal/frontend.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/stcgal/frontend.py b/stcgal/frontend.py index 0f058f6..da151c7 100644 --- a/stcgal/frontend.py +++ b/stcgal/frontend.py @@ -209,8 +209,8 @@ class StcGal: def cli(): # check arguments parser = argparse.ArgumentParser(formatter_class=argparse.RawDescriptionHelpFormatter, - description="stcgal %s - an STC MCU ISP flash tool\n" + - "(C) 2014-2017 Grigori Goronzy\nhttps://github.com/grigorig/stcgal" %stcgal.__version__) + description="stcgal {} - an STC MCU ISP flash tool\n".format(stcgal.__version__) + + "(C) 2014-2017 Grigori Goronzy\nhttps://github.com/grigorig/stcgal") parser.add_argument("code_image", help="code segment file to flash (BIN/HEX)", type=argparse.FileType("rb"), nargs='?') parser.add_argument("eeprom_image", help="eeprom segment file to flash (BIN/HEX)", type=argparse.FileType("rb"), nargs='?') parser.add_argument("-a", "--autoreset", help="cycle power automatically by asserting DTR", action="store_true")