diff --git a/cli.py b/cli.py index 7dfd08a..79383f2 100644 --- a/cli.py +++ b/cli.py @@ -37,9 +37,21 @@ def help(_args): for command in commandList.keys(): print("\t", command) +def issueUpdate(args): + parser = argparse.ArgumentParser(description='Update issues', prog="cli.py issueUpdate") + parser.add_argument('-v', '--verbose', action='store_true', help='verbose mode') + parser.add_argument('--outDir', default="build", help='output directory') + args = parser.parse_args(args) + if args.verbose: + print("update issues") + issuePath = os.path.join(args.outDir,"issues.json") + p = subprocess.run(["deno", "run", "-A","tools/getIssue.ts", "--path",issuePath]) + p.check_returncode() + commandList = { 'build': build, - 'help': help + 'help': help, + 'issueUpdate': issueUpdate } def main():