aboutsummaryrefslogtreecommitdiff
path: root/home/.sbt/0.13/build.sbt
blob: 2c529c1d3ffda35c75fb837916d48cd58508cb8d (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
// configure gpg
import com.typesafe.sbt.pgp.PgpKeys._
gpgCommand in Global := "gpg2"
pgpSigningKey in Global := Some(0x2CED17AB2B6D6F37l)
useGpgAgent in Global := true
useGpg in Global := true

// use ensime snapshot version
import org.ensime.EnsimeCoursierKeys._
ensimeServerVersion in ThisBuild := "2.0.0-SNAPSHOT"

// don't create target directory when starting sbt in non-project directory
// (e.g. when running sbt-new)
import java.nio.file.Files
target := {
  val buildSbt = new File("build.sbt")
  val projectSbt = new File("project.sbt")
  val project = new File("project")

  if (buildSbt.exists || projectSbt.exists || project.exists)
    target.value
  else
    Files.createTempDirectory("sbt-new").toFile
}