from argparse import ArgumentParser from dataclasses import dataclass from compiler import compile @dataclass class Arguments: workdir: str template: str out: str force: str def __init__(self): pass def main(): parser = ArgumentParser() parser.add_argument('workdir', action='store') parser.add_argument('-t' , '--template', action='store') parser.add_argument('-o', '--out', action='store') parser.add_argument('-f', '--force', action='store_true', default=False) args = Arguments() parser.parse_args(namespace=args) compile(args.workdir, args.template, args.out, args.force) if __name__ == "__main__": main()