3
0
Fork 0
forked from mirrors/nixpkgs

sbt: add JAVA_HOME to sbt script

This commit is contained in:
Profpatsch 2015-08-07 18:46:23 +02:00
parent 9966ec4e54
commit 062cdfb3a1

View file

@ -15,6 +15,9 @@ stdenv.mkDerivation rec {
mkdir -p $out/bin mkdir -p $out/bin
cat > $out/bin/sbt << EOF cat > $out/bin/sbt << EOF
#! ${stdenv.shell} #! ${stdenv.shell}
if [ ! -v JAVA_HOME ]; then
export JAVA_HOME="${jre.home}"
fi
${jre}/bin/java \$SBT_OPTS -jar ${src} "\$@" ${jre}/bin/java \$SBT_OPTS -jar ${src} "\$@"
EOF EOF
chmod +x $out/bin/sbt chmod +x $out/bin/sbt