1 # Maintainer: jpate <j.k.pate@sms.ed.ac.uk>
6 pkgdesc="Simple-build-tool: A build tool for Scala"
8 url="https://github.com/harrah/xsbt/"
9 license=('New BSD License')
10 depends=( 'java-runtime' )
11 source=( "http://typesafe.artifactoryonline.com/typesafe/ivy-releases/org.scala-tools.sbt/sbt-launch/${pkgver}/sbt-launch.jar" )
12 noextract=('sbt-launch.jar')
13 md5sums=('2886cc391e38fa233b3e6c0ec9adfa1e')
18 mkdir -p $pkgdir/usr/bin/
19 mkdir -p $pkgdir/usr/share/sbt/
20 cp $srcdir/sbt-launch.jar $pkgdir/usr/share/sbt/
22 cat > $pkgdir/usr/bin/sbt <<EOF
24 if [[ -n "\$JAVA_HOME" ]]; then
25 JAVA_CMD=\$JAVA_HOME/bin/java
27 JAVA_CMD=\$(which java)
29 if [[ -z "\$JAVA_ARGS" ]]; then
33 echo "\$JAVA_CMD \$JAVA_ARGS \${SBT_OPTS} -jar /usr/share/sbt/sbt-launch.jar \"\$@\"" >> $pkgdir/usr/bin/sbt
35 chmod a+x $pkgdir/usr/bin/sbt