forked from cloudify/sPDF
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathbuild.sbt
125 lines (91 loc) · 2.87 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
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
name := "sPDF"
description := "Create PDFs using plain old HTML+CSS. Uses wkhtmltopdf on the back-end which renders HTML using Webkit."
homepage := Some(url("https://github.com/cloudify/sPDF"))
startYear := Some(2013)
licenses := Seq(
("MIT", url("http://opensource.org/licenses/MIT"))
)
organization := "io.github.cloudify"
version := "1.0.0"
/* scala versions and options */
scalaVersion := "2.10.2"
crossScalaVersions := Seq("2.9.1", "2.9.2", "2.9.3", "2.10.0", "2.10.1", "2.10.2")
// These options will be used for *all* versions.
scalacOptions ++= Seq(
"-deprecation",
"-unchecked",
"-encoding", "UTF-8"
// "-Xcheckinit" // for debugging only, see https://github.com/paulp/scala-faq/wiki/Initialization-Order
// "-optimise" // this option will slow your build
)
scalacOptions ++= Seq(
"-Yclosure-elim",
"-Yinline"
)
// These language flags will be used only for 2.10.x.
// Uncomment those you need, or if you hate SIP-18, all of them.
scalacOptions <++= scalaVersion map { sv =>
if (sv startsWith "2.10") List(
"-Xverify",
"-Ywarn-all",
"-feature"
// "-language:postfixOps",
// "-language:reflectiveCalls",
// "-language:implicitConversions"
// "-language:higherKinds",
// "-language:existentials",
// "-language:experimental.macros",
// "-language:experimental.dynamics"
)
else Nil
}
fork in Test := true
parallelExecution in Test := false
/* sbt behavior */
logLevel in compile := Level.Warn
traceLevel := 5
offline := false
scmInfo := Some(
ScmInfo(
url("https://github.com/cloudify/sPDF"),
"scm:git:https://github.com/cloudify/sPDF.git",
Some("scm:git:[email protected]:cloudify/sPDF.git")
)
)
/* dependencies */
libraryDependencies ++= Seq (
"org.scalatest" %% "scalatest" % "1.9.1" % "test",
"org.mockito" % "mockito-all" % "1.9.0" % "test"
)
/* publishing */
publishMavenStyle := true
publishTo <<= version { (v: String) =>
val nexus = "https://oss.sonatype.org/"
if (v.trim.endsWith("SNAPSHOT"))
Some("snapshots" at nexus + "content/repositories/snapshots")
else
Some("releases" at nexus + "service/local/staging/deploy/maven2")
}
credentials += Credentials(Path.userHome / ".credentials.sonatype")
publishArtifact in Test := false
// publishArtifact in (Compile, packageDoc) := false
// publishArtifact in (Compile, packageSrc) := false
pomIncludeRepository := { _ => false }
pomExtra := (
<developers>
<developer>
<id>cloudify</id>
<name>Federico Feroldi</name>
<email>[email protected]</email>
<url>http://www.pixzone.com</url>
</developer>
</developers>
)
// Josh Suereth's step-by-step guide to publishing on sonatype
// http://www.scala-sbt.org/using_sonatype.html
site.settings
site.includeScaladoc()
ghpages.settings
git.remoteRepo := "[email protected]:cloudify/sPDF.git"
seq(lsSettings:_*)
(LsKeys.tags in LsKeys.lsync) := Seq("pdf", "webkit")