#!/bin/bash

OKAPI_HOME="${OKAPI_HOME:-$(dirname "$0")/../../../}"

JAVA="jdk-17.0.15+6-jre/Contents/Home/bin/java"

if [ -z "$JAVA" ]; then
    exit 1
fi

# Get rid of process serial number from GUI launch
if [[ "$*" == -psn* ]]; then
    shift
fi

exec "$JAVA" -XstartOnFirstThread -Xdock:name="Rainbow" -cp "lib/*" net.sf.okapi.applications.rainbow.Main "$@"
