-
Notifications
You must be signed in to change notification settings - Fork 1
/
build.sbt
78 lines (69 loc) · 2.45 KB
/
build.sbt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
import xerial.sbt.Sonatype.autoImport.sonatypeProfileName
import ReleaseTransformations._
lazy val compilerSettings = Seq(
scalacOptions ++= Seq(
"-language:higherKinds",
"-Ypartial-unification",
"-Yliteral-types",
"-encoding", "UTF-8",
"-language:implicitConversions",
"-language:postfixOps",
"-language:existentials"
),
addCompilerPlugin("org.spire-math" %% "kind-projector" % "0.9.3"),
addCompilerPlugin("com.github.mpilquist" %% "simulacrum" % "0.10.0")
)
lazy val commonResolvers = Seq(
Resolver.sonatypeRepo("releases"),
Resolver.sonatypeRepo("snapshots"),
Resolver.jcenterRepo
)
lazy val buildSettings = Seq(
scalaOrganization := "org.typelevel",
scalaVersion := "2.12.1",
organization := "com.github.to-ithaca",
name := "theseus"
)
lazy val catsVersion = "0.9.0"
lazy val commonSettings = Seq(
resolvers := commonResolvers,
libraryDependencies ++= Seq(
"org.typelevel" %% "cats-core" % catsVersion,
"org.typelevel" %% "cats-free" % catsVersion,
"com.chuusai" %% "shapeless" % "2.3.2",
"org.scalatest" %% "scalatest" % "3.0.1" % "test",
"org.scalacheck" %% "scalacheck" % "1.13.4" % "test"
)
) ++ compilerSettings
val publishSettings = Seq(
releaseCrossBuild := true,
releaseIgnoreUntrackedFiles := true,
sonatypeProfileName := "com.github.to-ithaca",
developers += Developer("zainab-ali", "Zainab Ali", "", url("http://github.com/zainab-ali")),
licenses := Seq("Apache-2.0" -> url("https://www.apache.org/licenses/LICENSE-2.0.html")),
homepage := Some(url("https://github.com/to-ithaca/theseus")),
scmInfo := Some(ScmInfo(url("https://github.com/to-ithaca/theseus"),
"[email protected]:to-ithaca/theseus")),
credentials ++= (for {
username <- Option(System.getenv().get("SONATYPE_USERNAME"))
password <- Option(System.getenv().get("SONATYPE_PASSWORD"))
} yield Credentials("Sonatype Nexus Repository Manager", "oss.sonatype.org", username, password)).toSeq,
releaseProcess := Seq[ReleaseStep](
checkSnapshotDependencies,
inquireVersions,
runClean,
runTest,
setReleaseVersion,
commitReleaseVersion,
tagRelease,
ReleaseStep(action = Command.process("publishSigned", _), enableCrossBuild = true),
setNextVersion,
commitNextVersion,
ReleaseStep(action = Command.process("sonatypeReleaseAll", _), enableCrossBuild = true),
pushChanges)
)
lazy val root = (project in file(".")).settings(
buildSettings,
commonSettings,
publishSettings
)