From f59a6c44c3d4fb4492e382bbe41efbc6d939defe Mon Sep 17 00:00:00 2001 From: Lars Hupel Date: Fri, 21 Oct 2016 21:50:49 +0200 Subject: [PATCH 01/10] dependency updates in preparation for Scala 2.12.x --- build.sbt | 11 +++-------- project/plugins.sbt | 4 ++-- 2 files changed, 5 insertions(+), 10 deletions(-) diff --git a/build.sbt b/build.sbt index 7df37f01a..23bddc526 100644 --- a/build.sbt +++ b/build.sbt @@ -74,11 +74,6 @@ lazy val scalaVersionAgnosticCommonSettings = Seq( "Scalaz Bintray Repo" at "http://dl.bintray.com/scalaz/releases", Resolver.sonatypeRepo("releases") ), - scalacOptions += "-target:jvm-1.7", - javacOptions ++= Seq( - "-source", "1.7", - "-target", "1.7" - ), javacOptions in Keys.doc := Seq() ) ++ releaseSettings @@ -87,7 +82,7 @@ lazy val commonSettings = scalaVersionAgnosticCommonSettings ++ Seq( crossScalaVersions := Seq("2.11.8", "2.10.6"), libraryDependencies ++= { if (scalaBinaryVersion.value == "2.10") - Seq(compilerPlugin("org.scalamacros" % "paradise" % "2.0.1" cross CrossVersion.full)) + Seq(compilerPlugin("org.scalamacros" % "paradise" % "2.1.0" cross CrossVersion.full)) else Seq() } @@ -102,7 +97,7 @@ lazy val core = crossProject name := "coursier", libraryDependencies ++= Seq( "org.scalaz" %%% "scalaz-core" % scalazVersion, - "com.lihaoyi" %%% "fastparse" % "0.3.7" + "com.lihaoyi" %%% "fastparse" % "0.4.1" ), resourceGenerators.in(Compile) += { (target, version).map { (dir, ver) => @@ -236,7 +231,7 @@ lazy val tests = crossProject name := "coursier-tests", libraryDependencies ++= Seq( "org.scala-lang.modules" %% "scala-async" % "0.9.5" % "provided", - "com.lihaoyi" %%% "utest" % "0.4.3" % "test" + "com.lihaoyi" %%% "utest" % "0.4.4" % "test" ), unmanagedResourceDirectories in Test += (baseDirectory in LocalRootProject).value / "tests" / "shared" / "src" / "test" / "resources", testFrameworks += new TestFramework("utest.runner.Framework") diff --git a/project/plugins.sbt b/project/plugins.sbt index b5d5bb769..7e32d92a5 100644 --- a/project/plugins.sbt +++ b/project/plugins.sbt @@ -1,8 +1,8 @@ addSbtPlugin("org.xerial.sbt" % "sbt-pack" % "0.8.0") -addSbtPlugin("org.scala-js" % "sbt-scalajs" % "0.6.11") +addSbtPlugin("org.scala-js" % "sbt-scalajs" % "0.6.13") addSbtPlugin("com.jsuereth" % "sbt-pgp" % "1.0.0") addSbtPlugin("org.scoverage" % "sbt-scoverage" % "1.1.0") -addSbtPlugin("org.tpolecat" % "tut-plugin" % "0.4.2") +addSbtPlugin("org.tpolecat" % "tut-plugin" % "0.4.5") addSbtPlugin("io.get-coursier" % "sbt-coursier" % "1.0.0-M14") addSbtPlugin("com.typesafe.sbt" % "sbt-proguard" % "0.2.2") addSbtPlugin("com.typesafe" % "sbt-mima-plugin" % "0.1.9") From 4b14215c3344c6dddf6cc6e689101b858158b4d1 Mon Sep 17 00:00:00 2001 From: Alexandre Archambault Date: Sat, 22 Oct 2016 01:35:57 +0200 Subject: [PATCH 02/10] Prepare build.sbt for 2.12, keep updating dependencies --- .travis.yml | 3 + build.sbt | 92 +++++++++++-------- .../coursier/HttpServer.scala | 0 project/plugins.sbt | 4 +- .../coursier_2.11/1.0.0-SNAPSHOT | 8 +- 5 files changed, 61 insertions(+), 46 deletions(-) rename http-server/src/main/{scala => scala-2.11}/coursier/HttpServer.scala (100%) diff --git a/.travis.yml b/.travis.yml index 2f6ffe43f..f3e6666e8 100644 --- a/.travis.yml +++ b/.travis.yml @@ -12,6 +12,9 @@ script: # - bash <(curl -s https://codecov.io/bash) matrix: include: + - env: TRAVIS_SCALA_VERSION=2.12.0-RC2 PUBLISH=1 + os: linux + jdk: oraclejdk8 - env: TRAVIS_SCALA_VERSION=2.11.8 PUBLISH=1 os: linux jdk: oraclejdk8 diff --git a/build.sbt b/build.sbt index 23bddc526..dafb9a93c 100644 --- a/build.sbt +++ b/build.sbt @@ -47,21 +47,21 @@ lazy val noPublishSettings = Seq( publishArtifact := false ) -def noPublishForScalaVersionSettings(sbv: String) = Seq( +def noPublishForScalaVersionSettings(sbv: String*) = Seq( publish := { - if (scalaBinaryVersion.value == sbv) + if (sbv.contains(scalaBinaryVersion.value)) () else publish.value }, publishLocal := { - if (scalaBinaryVersion.value == sbv) + if (sbv.contains(scalaBinaryVersion.value)) () else publishLocal.value }, publishArtifact := { - if (scalaBinaryVersion.value == sbv) + if (sbv.contains(scalaBinaryVersion.value)) false else publishArtifact.value @@ -88,7 +88,7 @@ lazy val commonSettings = scalaVersionAgnosticCommonSettings ++ Seq( } ) -val scalazVersion = "7.2.5" +val scalazVersion = "7.2.6" lazy val core = crossProject .settings(commonSettings: _*) @@ -97,7 +97,7 @@ lazy val core = crossProject name := "coursier", libraryDependencies ++= Seq( "org.scalaz" %%% "scalaz-core" % scalazVersion, - "com.lihaoyi" %%% "fastparse" % "0.4.1" + "com.lihaoyi" %%% "fastparse" % "0.4.2" ), resourceGenerators.in(Compile) += { (target, version).map { (dir, ver) => @@ -229,10 +229,16 @@ lazy val tests = crossProject .settings(Defaults.itSettings: _*) .settings( name := "coursier-tests", - libraryDependencies ++= Seq( - "org.scala-lang.modules" %% "scala-async" % "0.9.5" % "provided", - "com.lihaoyi" %%% "utest" % "0.4.4" % "test" - ), + libraryDependencies += { + val asyncVersion = + if (scalaBinaryVersion.value == "2.10") + "0.9.5" + else + "0.9.6-RC6" + + "org.scala-lang.modules" %% "scala-async" % asyncVersion % "provided" + }, + libraryDependencies += "com.lihaoyi" %%% "utest" % "0.4.4" % "test", unmanagedResourceDirectories in Test += (baseDirectory in LocalRootProject).value / "tests" / "shared" / "src" / "test" / "resources", testFrameworks += new TestFramework("utest.runner.Framework") ) @@ -329,16 +335,16 @@ lazy val bootstrap = project lazy val cli = project .dependsOn(coreJvm, cache) .settings(commonSettings) - .settings(noPublishForScalaVersionSettings("2.10")) + .settings(noPublishForScalaVersionSettings("2.10", "2.12")) .settings(packAutoSettings) .settings(proguardSettings) .settings( name := "coursier-cli", libraryDependencies ++= { - if (scalaBinaryVersion.value == "2.10") - Seq() - else + if (scalaBinaryVersion.value == "2.11") Seq("com.github.alexarchambault" %% "case-app" % "1.1.2") + else + Seq() }, resourceGenerators in Compile += packageBin.in(bootstrap).in(Compile).map { jar => Seq(jar) @@ -352,16 +358,17 @@ lazy val cli = project javaOptions in (Proguard, ProguardKeys.proguard) := Seq("-Xmx3172M"), artifactPath in Proguard := (ProguardKeys.proguardDirectory in Proguard).value / "coursier-standalone.jar", artifacts ++= { - if (scalaBinaryVersion.value == "2.10") - Nil - else Seq( - Artifact( - moduleName.value, - "jar", - "jar", - "standalone" + if (scalaBinaryVersion.value == "2.11") + Seq( + Artifact( + moduleName.value, + "jar", + "jar", + "standalone" + ) ) - ) + else + Nil }, packagedArtifacts <++= { ( @@ -371,9 +378,7 @@ lazy val cli = project packageBin.in(bootstrap) in Compile ).map { (mod, sbv, files, bootstrapJar) => - if (sbv == "2.10") - Map.empty[Artifact, File] - else { + if (sbv == "2.11") { import java.util.zip.{ ZipEntry, ZipOutputStream, ZipInputStream } import java.io.{ ByteArrayOutputStream, FileInputStream, FileOutputStream, File, InputStream, IOException } @@ -450,7 +455,8 @@ lazy val cli = project "standalone" ) -> f ) - } + } else + Map.empty[Artifact, File] } } ) @@ -462,18 +468,18 @@ lazy val web = project .settings(noPublishSettings) .settings( libraryDependencies ++= { - if (scalaBinaryVersion.value == "2.10") - Seq() - else + if (scalaBinaryVersion.value == "2.11") Seq("com.github.japgolly.scalajs-react" %%% "core" % "0.9.0") + else + Seq() }, sourceDirectory := { val dir = sourceDirectory.value - if (scalaBinaryVersion.value == "2.10") - dir / "dummy" - else + if (scalaBinaryVersion.value == "2.11") dir + else + dir / "dummy" }, test in Test := (), testOnly in Test := (), @@ -500,7 +506,7 @@ lazy val doc = project lazy val plugin = project .dependsOn(coreJvm, cache) .settings(scalaVersionAgnosticCommonSettings) - .settings(noPublishForScalaVersionSettings("2.11")) + .settings(noPublishForScalaVersionSettings("2.11", "2.12")) .settings( name := "sbt-coursier", sbtPlugin := (scalaBinaryVersion.value == "2.10"), @@ -528,14 +534,20 @@ val http4sVersion = "0.8.6" lazy val `http-server` = project .settings(commonSettings) .settings(packAutoSettings) + .settings(noPublishForScalaVersionSettings("2.10", "2.12")) .settings( name := "http-server-java7", - libraryDependencies ++= Seq( - "org.http4s" %% "http4s-blazeserver" % http4sVersion, - "org.http4s" %% "http4s-dsl" % http4sVersion, - "org.slf4j" % "slf4j-nop" % "1.7.21", - "com.github.alexarchambault" %% "case-app" % "1.1.2" - ) + libraryDependencies ++= { + if (scalaBinaryVersion.value == "2.11") + Seq( + "org.http4s" %% "http4s-blazeserver" % http4sVersion, + "org.http4s" %% "http4s-dsl" % http4sVersion, + "org.slf4j" % "slf4j-nop" % "1.7.21", + "com.github.alexarchambault" %% "case-app" % "1.1.2" + ) + else + Seq() + } ) lazy val okhttp = project diff --git a/http-server/src/main/scala/coursier/HttpServer.scala b/http-server/src/main/scala-2.11/coursier/HttpServer.scala similarity index 100% rename from http-server/src/main/scala/coursier/HttpServer.scala rename to http-server/src/main/scala-2.11/coursier/HttpServer.scala diff --git a/project/plugins.sbt b/project/plugins.sbt index 7e32d92a5..213b7b1a9 100644 --- a/project/plugins.sbt +++ b/project/plugins.sbt @@ -1,9 +1,9 @@ addSbtPlugin("org.xerial.sbt" % "sbt-pack" % "0.8.0") addSbtPlugin("org.scala-js" % "sbt-scalajs" % "0.6.13") addSbtPlugin("com.jsuereth" % "sbt-pgp" % "1.0.0") -addSbtPlugin("org.scoverage" % "sbt-scoverage" % "1.1.0") +addSbtPlugin("org.scoverage" % "sbt-scoverage" % "1.4.0") addSbtPlugin("org.tpolecat" % "tut-plugin" % "0.4.5") addSbtPlugin("io.get-coursier" % "sbt-coursier" % "1.0.0-M14") addSbtPlugin("com.typesafe.sbt" % "sbt-proguard" % "0.2.2") -addSbtPlugin("com.typesafe" % "sbt-mima-plugin" % "0.1.9") +addSbtPlugin("com.typesafe" % "sbt-mima-plugin" % "0.1.11") libraryDependencies += "org.scala-sbt" % "scripted-plugin" % sbtVersion.value diff --git a/tests/shared/src/test/resources/resolutions/io.get-coursier/coursier_2.11/1.0.0-SNAPSHOT b/tests/shared/src/test/resources/resolutions/io.get-coursier/coursier_2.11/1.0.0-SNAPSHOT index ff45bfc0d..3382a209b 100644 --- a/tests/shared/src/test/resources/resolutions/io.get-coursier/coursier_2.11/1.0.0-SNAPSHOT +++ b/tests/shared/src/test/resources/resolutions/io.get-coursier/coursier_2.11/1.0.0-SNAPSHOT @@ -1,8 +1,8 @@ -com.lihaoyi:fastparse-utils_2.11:0.3.7:default -com.lihaoyi:fastparse_2.11:0.3.7:default -com.lihaoyi:sourcecode_2.11:0.1.1:default +com.lihaoyi:fastparse-utils_2.11:0.4.2:default +com.lihaoyi:fastparse_2.11:0.4.2:default +com.lihaoyi:sourcecode_2.11:0.1.3:default io.get-coursier:coursier_2.11:1.0.0-SNAPSHOT:compile org.jsoup:jsoup:1.9.2:default org.scala-lang:scala-library:2.11.8:default org.scala-lang.modules:scala-xml_2.11:1.0.5:default -org.scalaz:scalaz-core_2.11:7.2.5:default +org.scalaz:scalaz-core_2.11:7.2.6:default From d66f21636f256b181b5a23b302656d751f14ce7d Mon Sep 17 00:00:00 2001 From: Alexandre Archambault Date: Sat, 22 Oct 2016 22:24:41 +0200 Subject: [PATCH 03/10] Should now be fine with 2.12.0-RC2 --- build.sbt | 8 +++++--- core/shared/src/main/scala/coursier/ivy/IvyXml.scala | 3 ++- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/build.sbt b/build.sbt index dafb9a93c..ecf48c529 100644 --- a/build.sbt +++ b/build.sbt @@ -204,8 +204,7 @@ lazy val core = crossProject ) .jsSettings( libraryDependencies ++= Seq( - "org.scala-js" %%% "scalajs-dom" % "0.9.1", - "be.doeraene" %%% "scalajs-jquery" % "0.9.0" + "org.scala-js" %%% "scalajs-dom" % "0.9.1" ) ) @@ -469,7 +468,10 @@ lazy val web = project .settings( libraryDependencies ++= { if (scalaBinaryVersion.value == "2.11") - Seq("com.github.japgolly.scalajs-react" %%% "core" % "0.9.0") + Seq( + "be.doeraene" %%% "scalajs-jquery" % "0.9.0", + "com.github.japgolly.scalajs-react" %%% "core" % "0.9.0" + ) else Seq() }, diff --git a/core/shared/src/main/scala/coursier/ivy/IvyXml.scala b/core/shared/src/main/scala/coursier/ivy/IvyXml.scala index 3654688bf..3ada607c3 100644 --- a/core/shared/src/main/scala/coursier/ivy/IvyXml.scala +++ b/core/shared/src/main/scala/coursier/ivy/IvyXml.scala @@ -107,7 +107,8 @@ object IvyXml { .find(_.label == "info") .toRightDisjunction("Info not found") - (module, version) <- info(infoNode) + modVer <- info(infoNode) + (module, version) = modVer dependenciesNodeOpt = node.children .find(_.label == "dependencies") From 5eeb825bf5f355e6282ac8e889bd72c6d4b8c174 Mon Sep 17 00:00:00 2001 From: Alexandre Archambault Date: Sat, 22 Oct 2016 22:24:42 +0200 Subject: [PATCH 04/10] Dummy refacto --- .../src/main/scala/coursier/ivy/IvyXml.scala | 20 +++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/core/shared/src/main/scala/coursier/ivy/IvyXml.scala b/core/shared/src/main/scala/coursier/ivy/IvyXml.scala index 3ada607c3..464d3a5ab 100644 --- a/core/shared/src/main/scala/coursier/ivy/IvyXml.scala +++ b/core/shared/src/main/scala/coursier/ivy/IvyXml.scala @@ -108,26 +108,26 @@ object IvyXml { .toRightDisjunction("Info not found") modVer <- info(infoNode) - (module, version) = modVer + } yield { - dependenciesNodeOpt = node.children + val (module, version) = modVer + + val dependenciesNodeOpt = node.children .find(_.label == "dependencies") - dependencies0 = dependenciesNodeOpt.map(dependencies).getOrElse(Nil) + val dependencies0 = dependenciesNodeOpt.map(dependencies).getOrElse(Nil) - configurationsNodeOpt = node.children + val configurationsNodeOpt = node.children .find(_.label == "configurations") - configurationsOpt = configurationsNodeOpt.map(configurations) + val configurationsOpt = configurationsNodeOpt.map(configurations) - configurations0 = configurationsOpt.getOrElse(Seq("default" -> Seq.empty[String])) + val configurations0 = configurationsOpt.getOrElse(Seq("default" -> Seq.empty[String])) - publicationsNodeOpt = node.children + val publicationsNodeOpt = node.children .find(_.label == "publications") - publicationsOpt = publicationsNodeOpt.map(publications) - - } yield { + val publicationsOpt = publicationsNodeOpt.map(publications) val description = infoNode.children .find(_.label == "description") From fb9be8430de60a4381b77fc24fe7703428f214fa Mon Sep 17 00:00:00 2001 From: Alexandre Archambault Date: Sat, 22 Oct 2016 22:24:42 +0200 Subject: [PATCH 05/10] Don't generate property file in Scala JS It is actually only used from the JVM, as a resource --- build.sbt | 44 ++++++++++++++++++++++---------------------- 1 file changed, 22 insertions(+), 22 deletions(-) diff --git a/build.sbt b/build.sbt index ecf48c529..3311125df 100644 --- a/build.sbt +++ b/build.sbt @@ -99,27 +99,6 @@ lazy val core = crossProject "org.scalaz" %%% "scalaz-core" % scalazVersion, "com.lihaoyi" %%% "fastparse" % "0.4.2" ), - resourceGenerators.in(Compile) += { - (target, version).map { (dir, ver) => - import sys.process._ - - val f = dir / "coursier.properties" - dir.mkdirs() - - val p = new java.util.Properties - - p.setProperty("version", ver) - p.setProperty("commit-hash", Seq("git", "rev-parse", "HEAD").!!.trim) - - val w = new FileOutputStream(f) - p.store(w, "Coursier properties") - w.close() - - println(s"Wrote $f") - - Seq(f) - }.taskValue - }, mimaPreviousArtifacts := Set("com.github.alexarchambault" %% moduleName.value % binaryCompatibilityVersion), mimaBinaryIssueFilters ++= { import com.typesafe.tools.mima.core._ @@ -200,7 +179,28 @@ lazy val core = crossProject else Seq( "org.scala-lang.modules" %% "scala-xml" % "1.0.5" ) - } + }, + resourceGenerators.in(Compile) += { + (target, version).map { (dir, ver) => + import sys.process._ + + val f = dir / "coursier.properties" + dir.mkdirs() + + val p = new java.util.Properties + + p.setProperty("version", ver) + p.setProperty("commit-hash", Seq("git", "rev-parse", "HEAD").!!.trim) + + val w = new FileOutputStream(f) + p.store(w, "Coursier properties") + w.close() + + println(s"Wrote $f") + + Seq(f) + }.taskValue + } ) .jsSettings( libraryDependencies ++= Seq( From ac4ce5f4f53dfed8fa05799a342ca0f35732d34a Mon Sep 17 00:00:00 2001 From: Alexandre Archambault Date: Sat, 22 Oct 2016 22:24:42 +0200 Subject: [PATCH 06/10] Keep targetting Java 7 with scala 2.10 and 2.11 --- build.sbt | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/build.sbt b/build.sbt index 3311125df..bd49a90e2 100644 --- a/build.sbt +++ b/build.sbt @@ -74,6 +74,25 @@ lazy val scalaVersionAgnosticCommonSettings = Seq( "Scalaz Bintray Repo" at "http://dl.bintray.com/scalaz/releases", Resolver.sonatypeRepo("releases") ), + scalacOptions ++= { + scalaBinaryVersion.value match { + case "2.10" | "2.11" => + Seq("-target:jvm-1.7") + case _ => + Seq() + } + }, + javacOptions ++= { + scalaBinaryVersion.value match { + case "2.10" | "2.11" => + Seq( + "-source", "1.7", + "-target", "1.7" + ) + case _ => + Seq() + } + }, javacOptions in Keys.doc := Seq() ) ++ releaseSettings From 25788388ff2b09cb3d5e43ed7636bf3203e94a17 Mon Sep 17 00:00:00 2001 From: Alexandre Archambault Date: Sat, 22 Oct 2016 22:24:43 +0200 Subject: [PATCH 07/10] Fix message in test --- tests/shared/src/test/scala/coursier/test/CentralTests.scala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/shared/src/test/scala/coursier/test/CentralTests.scala b/tests/shared/src/test/scala/coursier/test/CentralTests.scala index d9a5022f2..61ad892ff 100644 --- a/tests/shared/src/test/scala/coursier/test/CentralTests.scala +++ b/tests/shared/src/test/scala/coursier/test/CentralTests.scala @@ -92,7 +92,7 @@ object CentralTests extends TestSuite { } for (((e, r), idx) <- expected.zip(result).zipWithIndex if e != r) - println(s"Line $idx:\n expected: $e\n got: $r") + println(s"Line ${idx + 1}:\n expected: $e\n got: $r") assert(result == expected) } From 88dd5d7574889d3b9c609e5219c75063e7b4056e Mon Sep 17 00:00:00 2001 From: Alexandre Archambault Date: Sat, 22 Oct 2016 22:27:14 +0200 Subject: [PATCH 08/10] Explicitly add 2.12.0-RC2 in crossScalaVersions Although crossScalaVersions is not really actually used here --- build.sbt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.sbt b/build.sbt index bd49a90e2..d20c2ac2a 100644 --- a/build.sbt +++ b/build.sbt @@ -98,7 +98,7 @@ lazy val scalaVersionAgnosticCommonSettings = Seq( lazy val commonSettings = scalaVersionAgnosticCommonSettings ++ Seq( scalaVersion := "2.11.8", - crossScalaVersions := Seq("2.11.8", "2.10.6"), + crossScalaVersions := Seq("2.12.0-RC2", "2.11.8", "2.10.6"), libraryDependencies ++= { if (scalaBinaryVersion.value == "2.10") Seq(compilerPlugin("org.scalamacros" % "paradise" % "2.1.0" cross CrossVersion.full)) From 5f2daac1184c00c08f1fc5ab1f069b2ef9cf3c36 Mon Sep 17 00:00:00 2001 From: Alexandre Archambault Date: Sat, 22 Oct 2016 22:43:08 +0200 Subject: [PATCH 09/10] Remove now unnecessary scala-js related settings --- build.sbt | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/build.sbt b/build.sbt index d20c2ac2a..ec228ba2d 100644 --- a/build.sbt +++ b/build.sbt @@ -261,9 +261,7 @@ lazy val tests = crossProject testFrameworks += new TestFramework("utest.runner.Framework") ) .jsSettings( - jsEnv := NodeJSEnv().value, - scalaJSStage in Global := FastOptStage, - scalaJSUseRhino in Global := false + scalaJSStage in Global := FastOptStage ) lazy val testsJvm = tests.jvm.dependsOn(cache % "test") From 7e836b51be2a91430714816adadb0a69acd3c2ca Mon Sep 17 00:00:00 2001 From: Alexandre Archambault Date: Sat, 22 Oct 2016 22:46:47 +0200 Subject: [PATCH 10/10] Disable mima checks for 2.12.0-RC2 for now No previous version published --- build.sbt | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/build.sbt b/build.sbt index ec228ba2d..da900e188 100644 --- a/build.sbt +++ b/build.sbt @@ -118,7 +118,14 @@ lazy val core = crossProject "org.scalaz" %%% "scalaz-core" % scalazVersion, "com.lihaoyi" %%% "fastparse" % "0.4.2" ), - mimaPreviousArtifacts := Set("com.github.alexarchambault" %% moduleName.value % binaryCompatibilityVersion), + mimaPreviousArtifacts := { + scalaBinaryVersion.value match { + case "2.10" | "2.11" => + Set("com.github.alexarchambault" %% moduleName.value % binaryCompatibilityVersion) + case _ => + Set() + } + }, mimaBinaryIssueFilters ++= { import com.typesafe.tools.mima.core._ @@ -274,7 +281,14 @@ lazy val cache = project .settings( name := "coursier-cache", libraryDependencies += "org.scalaz" %% "scalaz-concurrent" % scalazVersion, - mimaPreviousArtifacts := Set("com.github.alexarchambault" %% moduleName.value % binaryCompatibilityVersion), + mimaPreviousArtifacts := { + scalaBinaryVersion.value match { + case "2.10" | "2.11" => + Set("com.github.alexarchambault" %% moduleName.value % binaryCompatibilityVersion) + case _ => + Set() + } + }, mimaBinaryIssueFilters ++= { import com.typesafe.tools.mima.core._