This repository has been archived by the owner on Nov 10, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathbuild.sbt
78 lines (69 loc) · 2.71 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
organization := "com.github.carueda"
name := "cfg"
version := "0.3.0"
scalaVersion in ThisBuild := "2.12.8"
lazy val metaMacroSettings: Seq[Def.Setting[_]] = Seq(
// New-style macro annotations are under active development. As a result, in
// this build we'll be referring to snapshot versions of both scala.meta and
// macro paradise.
resolvers += Resolver.sonatypeRepo("releases"),
resolvers += Resolver.bintrayIvyRepo("scalameta", "maven"),
// A dependency on macro paradise 3.x is required to both write and expand
// new-style macros. This is similar to how it works for old-style macro
// annotations and a dependency on macro paradise 2.x.
addCompilerPlugin("org.scalameta" % "paradise" % "3.0.0-M11" cross CrossVersion.full),
scalacOptions += "-Xplugin-require:macroparadise",
// temporary workaround for https://github.com/scalameta/paradise/issues/10
scalacOptions in (Compile, console) := Seq(), // macroparadise plugin doesn't work in repl yet.
// temporary workaround for https://github.com/scalameta/paradise/issues/55
sources in (Compile, doc) := Nil // macroparadise doesn't work with scaladoc yet.
)
metaMacroSettings
// A dependency on scala.meta is required to write new-style macros, but not
// to expand such macros. This is similar to how it works for old-style
// macros and a dependency on scala.reflect.
libraryDependencies += "org.scalameta" %% "scalameta" % "1.8.0"
libraryDependencies ++= Seq(
"com.typesafe" % "config" % "1.3.1",
"com.lihaoyi" %% "utest" % "0.4.5" % "test"
)
testFrameworks += new TestFramework("utest.runner.Framework")
publishMavenStyle := true
publishArtifact in Test := false
publishTo := {
val nexus = "https://oss.sonatype.org/"
if (isSnapshot.value)
Some("snapshots" at nexus + "content/repositories/snapshots")
else
Some("releases" at nexus + "service/local/staging/deploy/maven2")
}
pomIncludeRepository := { _ => false }
homepage := Some(url("https://github.com/carueda/cfg"))
licenses := Seq("Apache 2.0" -> url("http://www.opensource.org/licenses/Apache-2.0"))
scmInfo := Some(ScmInfo(url("http://github.com/carueda/cfg"), "scm:git@github.com:carueda/cfg.git"))
pomExtra :=
<developers>
<developer>
<id>carueda</id>
<name>Carlos Rueda</name>
<url>http://carueda.info</url>
</developer>
</developers>;
// sonatypeProfileName := "com.github.carueda"
scalacOptions ++= Seq(
"-deprecation",
"-encoding", "UTF-8",
"-feature",
"-language:existentials",
"-language:higherKinds",
"-language:implicitConversions",
"-unchecked",
"-Xfatal-warnings",
"-Xlint",
"-Yno-adapted-args",
"-Ywarn-dead-code",
"-Ywarn-numeric-widen",
"-Ywarn-value-discard",
"-Xfuture",
"-Ywarn-unused-import"
)