11 lines
356 B
Bash
Executable File
11 lines
356 B
Bash
Executable File
#!/usr/bin/env bash
|
|
# Meridian OS — start local server on a stable port.
|
|
# Usage: ./serve.sh [port] (default 8921)
|
|
set -e
|
|
PORT="${1:-8921}"
|
|
cd "$(dirname "$0")"
|
|
# Kill any stale server on this port
|
|
lsof -ti:"$PORT" 2>/dev/null | xargs -r kill 2>/dev/null || true
|
|
echo "Serving Meridian OS at http://localhost:$PORT"
|
|
exec python3 -m http.server "$PORT"
|