#!/usr/bin/env bash
# One-click local dev + verification (Ubuntu native, Docker MySQL/Redis).
# Usage: bash scripts/local_verify.sh
set -euo pipefail
ROOT="$(cd "$(dirname "$0")/.." && pwd)"
cd "$ROOT"

echo "═══ Nexus local verify ═══"

bash scripts/start-dev.sh

echo ""
echo "── smoke ──"
bash scripts/local_integration_smoke.sh

echo ""
echo "── test_api ──"
"${ROOT}/.venv/bin/python" tests/test_api.py

echo ""
echo "── ruff (F) ──"
"${ROOT}/.venv/bin/ruff" check server/ --select F

echo ""
echo "═══ All local checks passed ═══"
