forked from qifun/json-stream
-
Notifications
You must be signed in to change notification settings - Fork 3
/
build.sbt
134 lines (99 loc) · 3.4 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
125
126
127
128
129
130
131
132
133
134
enablePlugins(AllHaxePlugins)
resolvers in ThisBuild += "Typesafe repository releases" at "http://repo.typesafe.com/typesafe/releases/"
for (c <- Seq(Compile, Test)) yield {
haxeOptions in c ++=
Seq("-D", "scala")
}
val haxelibs = Map(
"continuation" -> DependencyVersion.SpecificVersion("1.3.2"),
"microbuilder-HUGS" -> DependencyVersion.SpecificVersion("2.0.1")
)
haxelibDependencies ++= haxelibs
for (c <- AllTargetConfigurations ++ AllTestTargetConfigurations) yield {
haxeOptions in c ++= haxelibOptions(haxelibs)
}
for (c <- AllTargetConfigurations ++ AllTestTargetConfigurations) yield {
haxeOptions in c ++= Seq("-dce", "no")
}
for (c <- Seq(CSharp, TestCSharp)) yield {
haxeOptions in c ++= Seq("-D", "CF", "-D", "WITHOUTUNITY")
}
releaseUseGlobalVersion := false
releaseCrossBuild := true
haxeOptions in CSharp ++= Seq("-D", "dll")
for (c <- AllTestTargetConfigurations) yield {
haxeOptions in c ++= Seq("-main", "jsonStream.Main")
}
haxeOptions in Compile ++= Seq("--macro", "com.qifun.util.Patcher.noExternalDoc()")
javacOptions in Compile in compile += "-Xlint:-deprecation"
libraryDependencies += "org.scala-stm" %% "scala-stm" % "0.7"
libraryDependencies += "com.qifun" % "haxe-util" % "0.1.0" % HaxeJava classifier "haxe-java"
libraryDependencies += "com.qifun" %% "haxe-scala-library" % "0.2.1" % HaxeJava classifier "haxe-java"
libraryDependencies += "com.qifun.sbt-haxe" %% "test-interface" % "0.1.0" % Test
libraryDependencies += "com.qifun" %% "haxe-scala-stm" % "0.1.4" % HaxeJava classifier "haxe-java"
libraryDependencies += "org.reactivemongo" %% "reactivemongo-bson" % "0.11.6"
crossScalaVersions := Seq("2.10.4", "2.11.2")
doc in Compile := {
(doc in Compile).result.value.toEither match {
case Left(_) => {
// Ignore error
(target in doc in Compile).value
}
case Right(right) => {
right
}
}
}
organization := "com.thoughtworks.microbuilder"
name := "json-stream"
homepage := Some(url(s"https://github.com/ThoughtWorksInc/${name.value}"))
startYear := Some(2014)
licenses := Seq("Apache" -> url("http://www.apache.org/licenses/LICENSE-2.0.html"))
releasePublishArtifactsAction := PgpKeys.publishSigned.value
import ReleaseTransformations._
releaseProcess := Seq[ReleaseStep](
checkSnapshotDependencies,
inquireVersions,
runClean,
runTest,
setReleaseVersion,
commitReleaseVersion,
tagRelease,
releaseStepTask(publish in Haxe),
publishArtifacts,
setNextVersion,
commitNextVersion,
releaseStepCommand("sonatypeRelease"),
pushChanges
)
scmInfo := Some(ScmInfo(
url(s"https://github.com/ThoughtWorksInc/${name.value}"),
s"scm:git:git://github.com/ThoughtWorksInc/${name.value}.git",
Some(s"scm:git:[email protected]:ThoughtWorksInc/${name.value}.git")))
developers := List(
Developer(
"Atry",
"杨博 (Yang Bo)",
url("https://github.com/Atry")
),
Developer(
"zxiy",
"张修羽 (Zhang Xiuyu)",
url("https://github.com/zxiy")
),
Developer(
"chank",
"方里权 (Fang Liquan)",
url("https://github.com/chank")
)
)
haxelibContributors := Seq("Atry")
haxelibReleaseNote := "Add ability to export schema in swagger spec format."
haxelibTags ++= Seq(
"cross", "cpp", "cs", "flash", "java", "javascript", "js", "neko", "php", "python", "nme",
"marshaller", "serialization", "serializer", "utility",
"json", "bson"
)