-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.sbt
43 lines (35 loc) · 1.53 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
import xerial.sbt.Sonatype._
name := "svalidate"
version := "1.0.1"
scalaVersion := "2.12.7"
organization := "com.github.vickumar1981"
description := "Simple and easy validations for Scala and Java"
sonatypeProjectHosting := Some(GitHubHosting("vickumar1981", "svalidate", "vickumar@gmail.com"))
publishMavenStyle := true
licenses := Seq("APL2" -> url("http://www.apache.org/licenses/LICENSE-2.0.txt"))
pomIncludeRepository := { _ => false }
publishArtifact in Test := false
crossScalaVersions := Seq("2.11.11", "2.12.7")
assemblyOption in assembly := (assemblyOption in assembly).value.copy(includeScala = false, includeDependency = false)
// Add sonatype repository settings
publishTo := Some(
if (isSnapshot.value)
Opts.resolver.sonatypeSnapshots
else
Opts.resolver.sonatypeStaging
)
credentials += Credentials(Path.userHome / ".ivy2" / ".credentials")
assemblyJarName := "svalidate_2.12-" + version.value + ".jar"
test in assembly := {}
libraryDependencies += "org.scalactic" %% "scalactic" % "3.0.1" % Test
libraryDependencies += "org.scalatest" %% "scalatest" % "3.0.1" % Test
libraryDependencies += "com.github.javafaker" % "javafaker" % "0.16" % Test
lazy val testScalastyle = taskKey[Unit]("testScalastyle")
testScalastyle := scalastyle.in(Test).toTask("").value
(test in Test) := ((test in Test) dependsOn testScalastyle).value
coverageExcludedPackages := "<empty>"
coverageEnabled in(Test, compile) := true
coverageEnabled in(Compile, compile) := false
coverageMinimum := 100
coverageFailOnMinimum := true
scalastyleFailOnWarning := true