Skip to content

Commit 18b2f70

Browse files
authored
Merge pull request #4432 from djspiewak/build/sonatype
2 parents a429cfd + 03d2d5c commit 18b2f70

File tree

4 files changed

+42
-30
lines changed

4 files changed

+42
-30
lines changed

build.sbt

Lines changed: 23 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@
1515
*/
1616

1717
import java.io.File
18-
import java.util.concurrent.TimeUnit
1918

2019
import com.typesafe.tools.mima.core._
2120
import com.github.sbt.git.SbtGit.GitKeys._
@@ -46,7 +45,6 @@ ThisBuild / tlUntaggedAreSnapshots := false
4645

4746
ThisBuild / organization := "org.typelevel"
4847
ThisBuild / organizationName := "Typelevel"
49-
ThisBuild / tlSonatypeUseLegacyHost := false
5048

5149
ThisBuild / startYear := Some(2020)
5250

@@ -331,18 +329,31 @@ val CoopVersion = "1.2.0"
331329

332330
val MacrotaskExecutorVersion = "1.1.1"
333331

334-
tlReplaceCommandAlias("ci", CI.AllCIs.map(_.toString).mkString)
335-
addCommandAlias("release", "tlRelease")
332+
Global / tlCommandAliases ++= Map(
333+
CI.JVM.commandAlias,
334+
CI.Native.commandAlias,
335+
CI.JS.commandAlias,
336+
CI.Firefox.commandAlias,
337+
CI.Chrome.commandAlias
338+
)
339+
340+
Global / tlCommandAliases ++= Map(
341+
"ci" -> CI.AllCIs.flatMap(_.commands)
342+
)
336343

337-
addCommandAlias(CI.JVM.command, CI.JVM.toString)
338-
addCommandAlias(CI.Native.command, CI.Native.toString)
339-
addCommandAlias(CI.JS.command, CI.JS.toString)
340-
addCommandAlias(CI.Firefox.command, CI.Firefox.toString)
341-
addCommandAlias(CI.Chrome.command, CI.Chrome.toString)
344+
Global / tlCommandAliases ++= Map(
345+
"release" -> List("tlRelease")
346+
)
342347

343-
tlReplaceCommandAlias(
344-
"prePR",
345-
"; root/clean; +root/headerCreate; root/scalafixAll; scalafmtSbt; +root/scalafmtAll")
348+
Global / tlCommandAliases ++= Map(
349+
"prePR" -> List(
350+
"root/clean",
351+
"+root/headerCreate",
352+
"root/scalafixAll",
353+
"scalafmtSbt",
354+
"+root/scalafmtAll"
355+
)
356+
)
346357

347358
val jsProjects: Seq[ProjectReference] =
348359
Seq(

project/CI.scala

Lines changed: 17 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -23,24 +23,25 @@ sealed abstract class CI(
2323
scaladoc: Boolean,
2424
suffixCommands: List[String]) {
2525

26-
override val toString: String = {
27-
val commands =
28-
(List(
29-
"scalafmtSbtCheck",
30-
s"project $rootProject",
31-
jsEnv.fold("")(env => s"set Global / useJSEnv := JSEnv.$env"),
32-
"headerCheck",
33-
"scalafmtCheckAll",
34-
"javafmtCheckAll",
35-
"clean"
36-
) ++ testCommands ++ List(
37-
jsEnv.fold("")(_ => s"set Global / useJSEnv := JSEnv.NodeJS"),
38-
if (mimaReport) "mimaReportBinaryIssues" else "",
39-
if (scaladoc) "doc" else ""
40-
)).filter(_.nonEmpty) ++ suffixCommands
26+
val commands: List[String] =
27+
(List(
28+
s"project $rootProject",
29+
jsEnv.fold("")(env => s"set Global / useJSEnv := JSEnv.$env"),
30+
"headerCheck",
31+
"scalafmtSbtCheck",
32+
"scalafmtCheckAll",
33+
"javafmtCheckAll",
34+
"clean"
35+
) ++ testCommands ++ List(
36+
jsEnv.fold("")(_ => s"set Global / useJSEnv := JSEnv.NodeJS"),
37+
if (mimaReport) "mimaReportBinaryIssues" else "",
38+
if (scaladoc) "doc" else ""
39+
)).filter(_.nonEmpty) ++ suffixCommands
4140

41+
val commandAlias: (String, List[String]) = command -> commands
42+
43+
override val toString: String =
4244
commands.mkString("; ", "; ", "")
43-
}
4445
}
4546

4647
object CI {

project/build.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
sbt.version=1.10.7
1+
sbt.version=1.11.2

project/plugins.sbt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
libraryDependencies += "org.scala-js" %% "scalajs-env-selenium" % "1.1.1"
22

3-
addSbtPlugin("org.typelevel" % "sbt-typelevel" % "0.7.5")
3+
addSbtPlugin("org.typelevel" % "sbt-typelevel" % "0.8.0")
44

55
addSbtPlugin("org.scala-js" % "sbt-scalajs" % "1.17.0")
66
addSbtPlugin("org.scala-native" % "sbt-scala-native" % "0.4.17")

0 commit comments

Comments
 (0)