forked from scalapb/scalapb-json4s
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.sbt
64 lines (52 loc) · 1.86 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
import ReleaseTransformations._
import scalapb.compiler.Version.scalapbVersion
scalaVersion := "2.13.5"
crossScalaVersions := Seq("2.12.13", "2.13.5")
ThisBuild / organization := "com.thesamet.scalapb"
name := "scalapb-json4s"
ThisBuild / scalacOptions ++= Seq("-deprecation") ++ {
CrossVersion.partialVersion(scalaVersion.value) match {
case Some((2, v)) if v <= 11 => List("-target:jvm-1.7")
case _ => Nil
}
}
releaseCrossBuild := true
ThisBuild / publishTo := sonatypePublishToBundle.value
releasePublishArtifactsAction := PgpKeys.publishSigned.value
releaseProcess := Seq[ReleaseStep](
checkSnapshotDependencies,
inquireVersions,
runClean,
runTest,
setReleaseVersion,
commitReleaseVersion,
tagRelease,
releaseStepCommandAndRemaining("+publishSigned"),
releaseStepCommand(s"sonatypeBundleRelease"),
setNextVersion,
commitNextVersion,
pushChanges
)
libraryDependencies ++= Seq(
"com.thesamet.scalapb" %% "scalapb-runtime" % scalapbVersion,
"com.thesamet.scalapb" %% "scalapb-runtime" % scalapbVersion % "protobuf,test",
"org.json4s" %% "json4s-jackson" % "3.6.11",
"org.scalatest" %% "scalatest" % "3.2.8" % "test",
"org.scalatestplus" %% "scalacheck-1-15" % "3.2.8.0" % "test",
"org.scala-lang.modules" %% "scala-collection-compat" % "2.4.3",
"com.google.protobuf" % "protobuf-java-util" % "3.16.0" % "test",
"com.google.protobuf" % "protobuf-java" % "3.16.0" % "protobuf"
)
lazy val root = (project in file("."))
.settings(
inConfig(Test)(sbtprotoc.ProtocPlugin.protobufConfigSettings),
PB.protocVersion := "3.11.4",
Compile / PB.targets := Nil,
Test / PB.targets := Seq(
PB.gens.java -> (Test / sourceManaged).value,
scalapb.gen(javaConversions = true) -> (Test / sourceManaged).value
)
)
mimaPreviousArtifacts := Set(
"com.thesamet.scalapb" %% "scalapb-json4s" % "0.10.0"
)