#!/usr/bin/env python3
from __future__ import annotations

import importlib.util
import sys
from pathlib import Path


COMMON = Path(__file__).resolve().parents[2] / "moc-build" / "scripts" / "moc_audit_common.py"
spec = importlib.util.spec_from_file_location("moc_audit_common", COMMON)
module = importlib.util.module_from_spec(spec)
assert spec.loader is not None
spec.loader.exec_module(module)


if __name__ == "__main__":
    try:
        module.main()
    except Exception as exc:
        print(f"ERROR: {exc}", file=sys.stderr)
        sys.exit(1)
