diff --git a/build.sbt b/build.sbt index d0e210e8..ae08a188 100644 --- a/build.sbt +++ b/build.sbt @@ -2,6 +2,8 @@ lazy val root = project.in(file(".")) .aggregate(parserCombinatorsJVM, parserCombinatorsJS, parserCombinatorsNative) .settings( publish / skip := true, + ThisBuild / versionScheme := Some("early-semver"), + ThisBuild / versionPolicyIntention := Compatibility.BinaryAndSourceCompatible ) lazy val parserCombinators = crossProject(JVMPlatform, JSPlatform, NativePlatform) @@ -9,7 +11,11 @@ lazy val parserCombinators = crossProject(JVMPlatform, JSPlatform, NativePlatfor .settings( ScalaModulePlugin.scalaModuleSettings, name := "scala-parser-combinators", - scalaModuleMimaPreviousVersion := None, // until we publish 1.2.0 + scalaModuleMimaPreviousVersion := (CrossVersion.partialVersion(scalaVersion.value) match { + // pending resolution of https://github.com/scalacenter/sbt-version-policy/issues/62 + case Some((3, _)) => None + case _ => Some("1.2.0-M2") + }), libraryDependencies += "junit" % "junit" % "4.13.2" % Test, libraryDependencies += "com.novocode" % "junit-interface" % "0.11" % Test, diff --git a/build.sh b/build.sh index 8a1dde8c..4aa5cd2e 100755 --- a/build.sh +++ b/build.sh @@ -53,4 +53,4 @@ export CI_SNAPSHOT_RELEASE="${projectPrefix}publish" # for now, until we're confident in the new release scripts, just close the staging repo. export CI_SONATYPE_RELEASE="; sonatypePrepare; sonatypeBundleUpload; sonatypeClose" -sbt clean ${projectPrefix}test ${projectPrefix}publishLocal $releaseTask +sbt clean ${projectPrefix}test ${projectPrefix}versionPolicyCheck ${projectPrefix}publishLocal $releaseTask diff --git a/project/plugins.sbt b/project/plugins.sbt index 808b305e..2d8f1468 100644 --- a/project/plugins.sbt +++ b/project/plugins.sbt @@ -12,4 +12,5 @@ addSbtPlugin("org.scala-js" % "sbt-scalajs" % scalaJSVersion) addSbtPlugin("org.portable-scala" % "sbt-scala-native-crossproject" % "1.0.0") addSbtPlugin("org.scala-native" % "sbt-scala-native" % scalaNativeVersion) +addSbtPlugin("ch.epfl.scala" % "sbt-version-policy" % "1.0.0-RC5") addSbtPlugin("ch.epfl.lamp" % "sbt-dotty" % "0.5.3")