#!/usr/bin/env python3
"""Thin entry point so the tool can be run from a checkout without installing it.

Deliberately has no ``.py`` extension.  A file named ``migr8.py`` in the project
root would be importable as the module ``migr8`` and would shadow the real
``src/migr8`` package for anything that puts the root on ``sys.path``, such as
``python -m pytest``.  Run this file as ``./migr8 ...`` or ``python migr8 ...``;
the installed console script is ``migr8``.
"""

from __future__ import annotations

import sys
from pathlib import Path

_SRC = Path(__file__).resolve().parent / "src"
if _SRC.is_dir() and str(_SRC) not in sys.path:
    sys.path.insert(0, str(_SRC))

from migr8.cli import main  # noqa: E402

if __name__ == "__main__":
    raise SystemExit(main())
