bin/isabelle_scala_script
author wenzelm
Wed, 20 Mar 2019 20:15:30 +0100
changeset 69926 110fff287217
parent 52116 abf9fcfa65cf
child 73705 ac07f6be27ea
permissions -rwxr-xr-x
access OCaml tools and libraries via ISABELLE_OCAMLFIND; OPAM setup is optional: it requires odd development tools that are not available in default OS installations (e.g. make, m4);

#!/usr/bin/env bash
#
# Author: Makarius
#
# Isabelle/Scala script wrapper.

if [ -L "$0" ]; then
  TARGET="$(LC_ALL=C ls -l "$0" | sed 's/.* -> //')"
  exec "$(cd "$(dirname "$0")"; cd "$(pwd -P)"; cd "$(dirname "$TARGET")"; pwd)/$(basename "$TARGET")" "$@"
fi


## settings

PRG="$(basename "$0")"

ISABELLE_HOME="$(cd "$(dirname "$0")"; cd "$(pwd -P)"; cd ..; pwd)"
source "$ISABELLE_HOME/lib/scripts/getsettings" || exit 2


## main

exec "$ISABELLE_TOOL" scala -howtorun:script -nocompdaemon "$@"