30 lines
753 B
Nix
30 lines
753 B
Nix
{ stdenv, fetchurl, jre }:
|
|
|
|
stdenv.mkDerivation rec {
|
|
name = "sbt-${version}";
|
|
version = "0.13.7";
|
|
|
|
src = fetchurl {
|
|
url = "http://repo.typesafe.com/typesafe/ivy-releases/org.scala-sbt/sbt-launch/${version}/sbt-launch.jar";
|
|
sha256 = "9673ca4611e6367955ae068d5888f7ae665ab013c3e8435ffe2ca94318c6d607";
|
|
};
|
|
|
|
phases = [ "installPhase" ];
|
|
|
|
installPhase = ''
|
|
mkdir -p $out/bin
|
|
cat > $out/bin/sbt << EOF
|
|
#! ${stdenv.shell}
|
|
${jre}/bin/java \$SBT_OPTS -jar ${src} "\$@"
|
|
EOF
|
|
chmod +x $out/bin/sbt
|
|
'';
|
|
|
|
meta = {
|
|
homepage = http://www.scala-sbt.org/;
|
|
license = stdenv.lib.licenses.bsd3;
|
|
description = "A build tool for Scala, Java and more";
|
|
maintainers = [ stdenv.lib.maintainers.rickynils ];
|
|
};
|
|
}
|