#!python
"""sandbroker-setup - thin entrypoint for the guided installer wizard.

The wizard logic lives in the importable package (sandbroker/setup.py). This
script is the executable shim, mirroring how the other bin/ helpers bootstrap the
package via sys.path so it runs both from a plain repo checkout AND from a
pipx/venv install (where `sandbroker` is importable directly).

    sandbroker-setup                 # user mode, no sudo
    sandbroker-setup --hardened      # dedicated uid + system service
    sandbroker-setup --dry-run       # print the plan, change nothing
    sandbroker-setup --yes           # non-interactive (accept defaults)

Usually reached as `sandbroker setup` (bin/sandbroker dispatches to this).
"""
import sys
from pathlib import Path

# Make the sibling `sandbroker` package importable when running from a checkout.
# Harmless under a pipx/venv install, where the package is already on the path.
_REPO = Path(__file__).resolve().parent.parent
if str(_REPO) not in sys.path:
    sys.path.insert(0, str(_REPO))

from sandbroker.setup import main  # noqa: E402

if __name__ == "__main__":
    sys.exit(main(sys.argv[1:]))
