#!/usr/bin/env bash
DIR="$(cd "$(dirname "$(readlink "$0" 2>/dev/null || echo "$0")")" && pwd)"
BINARY="$DIR/openfork"
if [ ! -f "$BINARY" ]; then
  echo "Error: openfork binary not found at $BINARY" >&2
  echo "The postinstall script may not have run. Try:" >&2
  echo "  cd node_modules/openfork && node postinstall.mjs" >&2
  exit 1
fi
exec "$BINARY" "$@"
