diff options
Diffstat (limited to 'test/CheckManpage.py')
-rwxr-xr-x | test/CheckManpage.py | 24 |
1 files changed, 4 insertions, 20 deletions
diff --git a/test/CheckManpage.py b/test/CheckManpage.py index 3da9d872..1795b77e 100755 --- a/test/CheckManpage.py +++ b/test/CheckManpage.py @@ -1,5 +1,4 @@ -#!/usr/bin/env python -# -*- coding: utf-8 -*- +#!/usr/bin/env python3 import sys import re @@ -20,24 +19,9 @@ class CheckManpage (CheckOptions): self.source_type = 'manpage' if __name__ == "__main__": - def getargs(): - parser = argparse.ArgumentParser(prog='CheckManpage', - description='Check that ledger options are documented in the manpage') - parser.add_argument('-l', '--ledger', - dest='ledger', - type=str, - action='store', - required=True, - help='the path to the ledger executable to test with') - parser.add_argument('-s', '--source', - dest='source', - type=str, - action='store', - required=True, - help='the path to the top level ledger source directory') - return parser.parse_args() - - args = getargs() + args = argparse.ArgumentParser(prog='CheckManpage', + description='Check that ledger options are documented in the manpage' + parents=[CheckOptions.parser()]).parse_args() script = CheckManpage(args) status = script.main() sys.exit(status) |