INNER CODE UNIT · Python
main
g-battaglia/kerykeion · cli/kerykeion_cli/__init__.py:20
def main(argv: list[str] | None = None) -> int:
"""Console-script entry point: parse, dispatch, and turn anything that escapes into a classified exit."""
from kerykeion_cli.app import run
from kerykeion_cli.errors import handle_uncaught
args = sys.argv[1:] if argv is None else list(argv)
try:
return run(args)
except SystemExit:
raise
except BaseException as exc: # noqa: BLE001 — the whole point is to catch all
handle_uncaught(exc)
if __name__ == "__main__":
sys.exit(main())