M1-PCA-Project/cli/role/admin/run.py

15 lines
387 B
Python

import argparse
from . import action
def run(parser: argparse.ArgumentParser, arguments: argparse.Namespace):
match arguments.action:
case "create":
action.create.run(parser, arguments)
case "init":
action.init.run(parser, arguments)
# if the subcommand is not known, show the help
case _:
parser.print_usage()