def main(self, args):
        """A main function for trying the code from the command line."""

        parser = optparse.OptionParser()
        parser.add_option(
            "-d", action="store_true", dest="dis",
            help="Disassemble"
        )
        parser.add_option(
            "-R", action="store_true", dest="recursive",
            help="Recurse to find source files"
        )
        parser.add_option(
            "-q", action="store_true", dest="quiet",
            help="Suppress output"
        )
        parser.add_option(
            "-s", action="store_true", dest="source",
            help="Show analyzed source"
        )
        parser.add_option(
            "-t", action="store_true", dest="tokens",
            help="Show tokens"
        )

        options, args = parser.parse_args()
        if options.recursive:
            if args:
                root = args[0]
            else:
                root = "."
            for root, _, _ in os.walk(root):
                for f in glob.glob(root + "/*.py"):
                    if not options.quiet:
                        print(f"Parsing {f}")
                    self.one_file(options, f)
        elif not args:
            parser.print_help()
        else:
            self.one_file(options, args[0])
A main function for trying the code from the command line.
lab/parser.py