Browse Source

Fixed argument parser bug

Signed-off-by: Rémi BERTHO <remi.bertho@dalan.fr>
master
Rémi BERTHO 4 years ago
parent
commit
dd5d3e8f43
Signed by: dalan GPG Key ID: EE3B917931C07B64
  1. 4
      SSnR.py

4
SSnR.py

@ -35,7 +35,7 @@ def main():
"""
# Parse arguments
parser = argparse.ArgumentParser(description='Search and replace tool for UTF-8 files',
prog='SSnR')
prog='SSnR', allow_abbrev=False)
regex_group = parser.add_argument_group('Regular expression', "Search and replace regular expression")
regex_group.add_argument('-ex', '--regex', help='Regex', required=True)
@ -59,7 +59,7 @@ def main():
required=False, action='store_true')
option_group.add_argument('-igc', '--ignore_case', help='Ignore the case',
required=False, action='store_true')
option_group.add_argument('-r', '--recursive', help='Use the regex input recrusivly in the folders',
option_group.add_argument('-r', '--recursive', help='Use the regex input recursivly in the folders',
required=False, action='store_true')
args = vars(parser.parse_args())

Loading…
Cancel
Save