Skip to content

Commit 50cc1af

Browse files
committed
upgrade to sbt 1
1 parent 7b3516c commit 50cc1af

File tree

3 files changed

+9
-16
lines changed

3 files changed

+9
-16
lines changed

build.sbt

+6-6
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
11
import ScalaModulePlugin._
22
import sbtcrossproject.{crossProject, CrossType}
33
import _root_.scalafix.sbt.BuildInfo.{scalafixVersion, scala212 => scalafixScala212}
4+
import sys.process._
45

56
lazy val commonSettings = Seq(
6-
// this line could be removed after https://github.com/scala/sbt-scala-module/issues/48 is fixed
7-
licenses := Seq(("Apache-2.0", url("https://www.apache.org/licenses/LICENSE-2.0"))),
87
headerLicense := Some(HeaderLicense.Custom(
98
s"""|Scala (https://www.scala-lang.org)
109
|
@@ -83,7 +82,7 @@ lazy val compat = MultiScalaCrossProject(JSPlatform, JVMPlatform)(
8382
val x = (baseDirectory in LocalRootProject).value.toURI.toString
8483
val y = "https://raw.githubusercontent.com/scala/scala-collection-compat/" + sys.process
8584
.Process("git rev-parse HEAD")
86-
.lines_!
85+
.lineStream_!
8786
.head
8887
s"-P:scalajs:mapSourceURI:$x->$y/"
8988
},
@@ -315,7 +314,7 @@ inThisBuild(
315314
state
316315
},
317316
commands += Command.command("ci") { state =>
318-
val toRun =
317+
val toRun: Seq[String] =
319318
if (isScalafmt) {
320319
Seq("scalafmt-test")
321320
} else {
@@ -359,7 +358,7 @@ inThisBuild(
359358
if (releaseVersion.nonEmpty && !isBinaryCompat) {
360359
List(
361360
preRelease,
362-
s"$projectPrefix/publish-signed"
361+
s"$projectPrefix/publishSigned"
363362
)
364363
} else {
365364
Nil
@@ -379,6 +378,7 @@ inThisBuild(
379378
toRun.foreach(println)
380379
println("---------")
381380

382-
toRun ::: state
381+
val newCommands = toRun.toList.map(Exec(_, None))
382+
state.copy(remainingCommands = newCommands ::: state.remainingCommands)
383383
}
384384
))

project/build.properties

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
sbt.version=0.13.18
1+
sbt.version=1.2.8

project/plugins.sbt

+2-9
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,9 @@
1-
if (System.getProperty("java.version").startsWith("1."))
2-
Seq()
3-
else
4-
// override to version that works on Java 11,
5-
// see https://github.com/scala/sbt-scala-module/issues/35
6-
Seq(addSbtPlugin("com.typesafe.sbt" % "sbt-osgi" % "0.9.3"))
7-
81
val scalaJSVersion = Option(System.getenv("SCALAJS_VERSION")).filter(_.nonEmpty).getOrElse("0.6.26")
92

103
addSbtPlugin("org.scala-js" % "sbt-scalajs" % scalaJSVersion)
114
addSbtPlugin("org.portable-scala" % "sbt-scalajs-crossproject" % "0.6.0")
12-
addSbtPlugin("org.scala-lang.modules" % "sbt-scala-module" % "1.0.14")
5+
addSbtPlugin("org.scala-lang.modules" % "sbt-scala-module" % "2.0.0")
136
addSbtPlugin("ch.epfl.scala" % "sbt-scalafix" % "0.9.4")
147
addSbtPlugin("com.eed3si9n" % "sbt-buildinfo" % "0.7.0")
15-
addSbtPlugin("com.typesafe.sbt" % "sbt-pgp" % "0.8.3")
8+
addSbtPlugin("com.jsuereth" % "sbt-pgp" % "1.1.2-1")
169
addSbtPlugin("de.heikoseeberger" % "sbt-header" % "5.0.0")

0 commit comments

Comments
 (0)