diff --git a/.travis.yml b/.travis.yml index 6f7e667c2..eca3b1567 100644 --- a/.travis.yml +++ b/.travis.yml @@ -6,7 +6,7 @@ language: scala env: global: - - TRAVIS_JDK=adopt@1.8.192-12 + - TRAVIS_JDK=adopt@1.11.0-1 # WHITESOURCE_PASSWORD= - secure: d3bu2KNwsVHwfhbGgO+gmRfDKBJhfICdCJFGWKf2w3Gv86AJZX9nuTYRxz0KtdvEHO5Xw8WTBZLPb2thSJqhw9OCm4J8TBAVqCP0ruUj4+aqBUFy4bVexQ6WKE6nWHs4JPzPk8c6uC1LG3hMuzlC8RGETXtL/n81Ef1u7NjyXjs= matrix: @@ -33,6 +33,15 @@ matrix: - SBT_CMD="scripted java/*" install: - /home/travis/.jabba/bin/jabba install openjdk@1.10 + - env: + - TRAVIS_JDK=adopt@1.8.192-12 + - SBT_CMD="scripted actions/*" + - env: + - TRAVIS_JDK=adopt@1.8.192-12 + - SBT_CMD="scripted source-dependencies/*1of3" + - env: + - TRAVIS_JDK=adopt@1.8.192-12 + - SBT_CMD="scripted dependency-management/*1of4" before_install: - curl -sL https://raw.githubusercontent.com/shyiko/jabba/0.11.0/install.sh | bash && . ~/.jabba/jabba.sh diff --git a/project/plugins.sbt b/project/plugins.sbt index fda55cf6e..c323f502c 100644 --- a/project/plugins.sbt +++ b/project/plugins.sbt @@ -7,4 +7,4 @@ addSbtPlugin("org.scala-sbt" % "sbt-contraband" % "0.4.1") addSbtPlugin("de.heikoseeberger" % "sbt-header" % "3.0.2") addSbtPlugin("com.eed3si9n" % "sbt-buildinfo" % "0.8.0") addSbtPlugin("com.lightbend" % "sbt-whitesource" % "0.1.9") -addSbtPlugin("com.eed3si9n" % "sbt-assembly" % "0.14.8") +addSbtPlugin("com.eed3si9n" % "sbt-assembly" % "0.14.9") diff --git a/sbt/src/sbt-test/actions/cross-multiproject/build.sbt b/sbt/src/sbt-test/actions/cross-multiproject/build.sbt index d0eff709c..c39cdf83a 100644 --- a/sbt/src/sbt-test/actions/cross-multiproject/build.sbt +++ b/sbt/src/sbt-test/actions/cross-multiproject/build.sbt @@ -1,31 +1,29 @@ -inThisBuild(List( - crossScalaVersions := Seq("2.12.1", "2.11.8") -)) +lazy val scala212 = "2.12.8" +lazy val scala213 = "2.13.0-M5" + +ThisBuild / crossScalaVersions := Seq(scala212, scala213) +ThisBuild / scalaVersion := scala212 lazy val rootProj = (project in file(".")) .aggregate(libProj, fooPlugin) .settings( - scalaVersion := "2.12.1" + crossScalaVersions := Nil, + addCommandAlias("build", "compile") ) lazy val libProj = (project in file("lib")) .settings( - name := "foo-lib", - scalaVersion := "2.12.1", - crossScalaVersions := Seq("2.12.1", "2.11.8") + name := "foo-lib" ) lazy val fooPlugin = (project in file("sbt-foo")) + .enablePlugins(SbtPlugin) .settings( name := "sbt-foo", - sbtPlugin := true, - scalaVersion := "2.12.1", - crossScalaVersions := Seq("2.12.1") + crossScalaVersions := Seq(scala212) ) lazy val extrasProj = (project in file("extras")) .settings( name := "foo-extras", ) - -addCommandAlias("build", "compile") diff --git a/sbt/src/sbt-test/actions/cross-multiproject/test b/sbt/src/sbt-test/actions/cross-multiproject/test index 5458dcaf6..ba4263197 100644 --- a/sbt/src/sbt-test/actions/cross-multiproject/test +++ b/sbt/src/sbt-test/actions/cross-multiproject/test @@ -1,55 +1,43 @@ > + compile - $ exists lib/target/scala-2.12 -$ exists lib/target/scala-2.11 +$ exists lib/target/scala-2.13.0-M5 $ exists sbt-foo/target/scala-2.12 --$ exists sbt-foo/target/scala-2.11 +-$ exists sbt-foo/target/scala-2.13.0-M5 > clean > + libProj/compile - $ exists lib/target/scala-2.12 -$ exists lib/target/scala-2.11 +$ exists lib/target/scala-2.13.0-M5 -$ exists sbt-foo/target/scala-2.12 --$ exists sbt-foo/target/scala-2.11 +-$ exists sbt-foo/target/scala-2.13.0-M5 +# test safe switching > clean -> ++ 2.12.1 compile - +> ++ 2.12.8 -v compile $ exists lib/target/scala-2.12 --$ exists lib/target/scala-2.11 +-$ exists lib/target/scala-2.13.0-M5 $ exists sbt-foo/target/scala-2.12 --$ exists sbt-foo/target/scala-2.11 +-$ exists sbt-foo/target/scala-2.13.0-M5 +# Test legacy cross build with command support +# > clean +# > + build +# $ exists lib/target/scala-2.12 +# $ exists lib/target/scala-2.13.0-M5 +# $ exists sbt-foo/target/scala-2.12 +# -$ exists sbt-foo/target/scala-2.13.0-M5 + +# Test ++ leaves crossScalaVersions unchanged > clean -> ++ 2.11.8 -v compile +> ++2.12.8 +> +extrasProj/compile +$ exists extras/target/scala-2.13.0-M5 +$ exists extras/target/scala-2.12 -$ exists lib/target/scala-2.11 +# test safe switching +> clean +> ++ 2.13.0-M5 -v compile +$ exists lib/target/scala-2.13.0-M5 -$ exists lib/target/scala-2.12 # -$ exists sbt-foo/target/scala-2.12 --$ exists sbt-foo/target/scala-2.11 - -# > clean -# > ++ 2.11.8! compile - -# $ exists lib/target/scala-2.11 -# -$ exists lib/target/scala-2.12 -# -$ exists sbt-foo/target/scala-2.12 -# $ exists sbt-foo/target/scala-2.11 - -> clean -# Test legacy cross build with command support -> + build - -# Uses the root project scala version config, which is only configured to build for Scala 2.12 -$ exists lib/target/scala-2.12 --$ exists lib/target/scala-2.11 -$ exists sbt-foo/target/scala-2.12 --$ exists sbt-foo/target/scala-2.11 - -> clean -# Test ++ leaves crossScalaVersions unchanged -> ++2.12.1 -> +extrasProj/compile -$ exists extras/target/scala-2.11 -$ exists extras/target/scala-2.12 +-$ exists sbt-foo/target/scala-2.13.0-M5 diff --git a/sbt/src/sbt-test/actions/cross-strict-aggregation/build.sbt b/sbt/src/sbt-test/actions/cross-strict-aggregation/build.sbt index 6c9759d4b..98a883e0b 100644 --- a/sbt/src/sbt-test/actions/cross-strict-aggregation/build.sbt +++ b/sbt/src/sbt-test/actions/cross-strict-aggregation/build.sbt @@ -1,13 +1,20 @@ +lazy val scala212 = "2.12.8" +lazy val scala213 = "2.13.0-M5" + +ThisBuild / scalaVersion := scala212 + lazy val root = (project in file(".")) .aggregate(core, module) + .settings( + crossScalaVersions := Nil + ) lazy val core = (project in file("core")) .settings( - scalaVersion := "2.12.4", - crossScalaVersions := Seq("2.11.11", "2.12.4")) + crossScalaVersions := Seq(scala212, scala213)) lazy val module = (project in file("module")) .dependsOn(core) .settings( - scalaVersion := "2.12.4", - crossScalaVersions := Seq("2.12.4")) + crossScalaVersions := Seq(scala212) + ) diff --git a/sbt/src/sbt-test/actions/cross-strict-aggregation/test b/sbt/src/sbt-test/actions/cross-strict-aggregation/test index 2e9408232..d7bfc8b65 100644 --- a/sbt/src/sbt-test/actions/cross-strict-aggregation/test +++ b/sbt/src/sbt-test/actions/cross-strict-aggregation/test @@ -1,7 +1,7 @@ -> ++2.12.0-magic -> ++2.11.11 compile +> ++2.13.0-M5 compile -$ exists core/target/scala-2.11 --$ exists module/target/scala-2.11 +$ exists core/target/scala-2.13.0-M5 +-$ exists module/target/scala-2.13.0-M5 -$ exists module/target/scala-2.12 diff --git a/sbt/src/sbt-test/actions/doc-file-options/build.sbt b/sbt/src/sbt-test/actions/doc-file-options/build.sbt index be9255579..2c56831c1 100644 --- a/sbt/src/sbt-test/actions/doc-file-options/build.sbt +++ b/sbt/src/sbt-test/actions/doc-file-options/build.sbt @@ -2,15 +2,16 @@ val newContents = "bbbbbbbbb" val rootContentFile = "root.txt" -scalaVersion := "2.10.2" +ThisBuild / scalaVersion := "2.12.8" -scalacOptions in (Compile, doc) := Seq("-doc-root-content", rootContentFile) - -TaskKey[Unit]("changeRootContent") := { - IO.write(file(rootContentFile), newContents) -} - -TaskKey[Unit]("check") := { - val packageHtml = (target in Compile in doc).value / "package.html" - assert(IO.read(packageHtml).contains(newContents), s"does not contains ${newContents} in ${packageHtml}" ) -} +lazy val root = (project in file(".")) + .settings( + Compile / doc / scalacOptions := Seq("-doc-root-content", rootContentFile), + TaskKey[Unit]("changeRootContent") := { + IO.write(file(rootContentFile), newContents) + }, + TaskKey[Unit]("check") := { + val packageHtml = (Compile / doc / target).value / "index.html" + assert(IO.read(packageHtml).contains(newContents), s"does not contains ${newContents} in ${packageHtml}" ) + } + ) diff --git a/sbt/src/sbt-test/actions/doc/build.sbt b/sbt/src/sbt-test/actions/doc/build.sbt new file mode 100644 index 000000000..5fa581aa3 --- /dev/null +++ b/sbt/src/sbt-test/actions/doc/build.sbt @@ -0,0 +1,5 @@ +lazy val root = (project in file(".")) + .settings( + crossPaths := false, + Compile / doc / scalacOptions += "-Xfatal-warnings" + ) diff --git a/sbt/src/sbt-test/actions/doc/test b/sbt/src/sbt-test/actions/doc/test index dd5ba0ed9..23839647f 100644 --- a/sbt/src/sbt-test/actions/doc/test +++ b/sbt/src/sbt-test/actions/doc/test @@ -1,7 +1,3 @@ -> 'set crossPaths := false' - -> 'set scalacOptions in (Compile, doc) += "-Xfatal-warnings"' - -> doc > 'set sources in (Compile, doc) := { val src = (sources in Compile).value; src.filterNot(_.getName contains "B") }' @@ -29,9 +25,9 @@ $ absent "target/api/java" > ; clean ; doc # pure java project, only javadoc at top level -$ exists "target/api/package-list" +$ exists "target/api/index.html" $ absent "target/api/index.js" -# pending +# pending # $ absent "target/api/scala" -#$ absent "target/api/java" +# $ absent "target/api/java" diff --git a/sbt/src/sbt-test/actions/generator/build.sbt b/sbt/src/sbt-test/actions/generator/build.sbt index 04b2a1b48..5672ed807 100644 --- a/sbt/src/sbt-test/actions/generator/build.sbt +++ b/sbt/src/sbt-test/actions/generator/build.sbt @@ -1,11 +1,14 @@ -scalaVersion := "2.11.8" - val buildInfo = taskKey[Seq[File]]("generates the build info") -buildInfo := { - val file = sourceManaged.value / "BuildInfo.scala" - IO.write(file, "object BuildInfo") - file :: Nil -} -sourceGenerators in Compile += buildInfo -sourceGenerators in Compile += Def.task { Nil } +ThisBuild / scalaVersion := "2.12.8" + +lazy val root = (project in file(".")) + .settings( + buildInfo := { + val file = sourceManaged.value / "BuildInfo.scala" + IO.write(file, "object BuildInfo") + file :: Nil + }, + sourceGenerators in Compile += buildInfo, + sourceGenerators in Compile += Def.task { Nil } + ) diff --git a/sbt/src/sbt-test/actions/generator/test b/sbt/src/sbt-test/actions/generator/test index 385612f46..b7ff4b2e4 100644 --- a/sbt/src/sbt-test/actions/generator/test +++ b/sbt/src/sbt-test/actions/generator/test @@ -1,2 +1,2 @@ > compile -$ exists target/scala-2.11/src_managed/BuildInfo.scala +$ exists target/scala-2.12/src_managed/BuildInfo.scala diff --git a/sbt/src/sbt-test/apiinfo/basic/build.sbt b/sbt/src/sbt-test/apiinfo/basic/build.sbt deleted file mode 100644 index cc6aa3d78..000000000 --- a/sbt/src/sbt-test/apiinfo/basic/build.sbt +++ /dev/null @@ -1,4 +0,0 @@ -lazy val root = (project in file(".")). - settings( - scalaVersion := "2.10.6" - ) diff --git a/sbt/src/sbt-test/apiinfo/basic/src/main/scala/testCase/FooUser.scala b/sbt/src/sbt-test/apiinfo/basic/src/main/scala/testCase/FooUser.scala deleted file mode 100644 index e2702a0e3..000000000 --- a/sbt/src/sbt-test/apiinfo/basic/src/main/scala/testCase/FooUser.scala +++ /dev/null @@ -1,3 +0,0 @@ -package testCase - -case class FooUser(@Foo a: Int) diff --git a/sbt/src/sbt-test/apiinfo/basic/src/main/scala/testCase/JFoo.java b/sbt/src/sbt-test/apiinfo/basic/src/main/scala/testCase/JFoo.java deleted file mode 100644 index e849d8df7..000000000 --- a/sbt/src/sbt-test/apiinfo/basic/src/main/scala/testCase/JFoo.java +++ /dev/null @@ -1,10 +0,0 @@ -package testCase; - -import java.lang.annotation.Retention; -import java.lang.annotation.RetentionPolicy; - - -@Retention(RetentionPolicy.RUNTIME) -public @interface JFoo { - -} diff --git a/sbt/src/sbt-test/apiinfo/basic/src/main/scala/testCase/annotations.scala b/sbt/src/sbt-test/apiinfo/basic/src/main/scala/testCase/annotations.scala deleted file mode 100644 index c74c28494..000000000 --- a/sbt/src/sbt-test/apiinfo/basic/src/main/scala/testCase/annotations.scala +++ /dev/null @@ -1,7 +0,0 @@ - -import annotation.target.field - - -package object testCase { - type Foo = JFoo @field; -} diff --git a/sbt/src/sbt-test/apiinfo/basic/test b/sbt/src/sbt-test/apiinfo/basic/test deleted file mode 100644 index 5df2af1f3..000000000 --- a/sbt/src/sbt-test/apiinfo/basic/test +++ /dev/null @@ -1 +0,0 @@ -> compile diff --git a/sbt/src/sbt-test/compiler-project/dotty-compiler-plugin/build.sbt b/sbt/src/sbt-test/compiler-project/dotty-compiler-plugin/build.sbt index 099cd9f71..124a017c3 100644 --- a/sbt/src/sbt-test/compiler-project/dotty-compiler-plugin/build.sbt +++ b/sbt/src/sbt-test/compiler-project/dotty-compiler-plugin/build.sbt @@ -1,16 +1,15 @@ -// hardcode dottyVersion to make test deterministic -lazy val dottyVersion = "0.8.0-bin-20180424-e77604d-NIGHTLY" +lazy val dottyVersion = "0.11.0-RC1" + +ThisBuild / scalaVersion := dottyVersion +ThisBuild / organization := "com.example" lazy val plugin = (project in file("plugin")) .settings( name := "dividezero", - version := "0.0.1", - organization := "ch.epfl.lamp", - scalaVersion := dottyVersion, + version := "0.0.1" ) lazy val app = (project in file(".")) .settings( - scalaVersion := dottyVersion, - libraryDependencies += compilerPlugin("ch.epfl.lamp" %% "dividezero" % "0.0.1"), + libraryDependencies += compilerPlugin("com.example" %% "dividezero" % "0.0.1"), ) diff --git a/sbt/src/sbt-test/compiler-project/dotty-compiler-plugin/test b/sbt/src/sbt-test/compiler-project/dotty-compiler-plugin/pending similarity index 100% rename from sbt/src/sbt-test/compiler-project/dotty-compiler-plugin/test rename to sbt/src/sbt-test/compiler-project/dotty-compiler-plugin/pending diff --git a/sbt/src/sbt-test/compiler-project/dotty-compiler-plugin/project/plugins.sbt b/sbt/src/sbt-test/compiler-project/dotty-compiler-plugin/project/plugins.sbt index ba89aa2bb..174dbbcb8 100644 --- a/sbt/src/sbt-test/compiler-project/dotty-compiler-plugin/project/plugins.sbt +++ b/sbt/src/sbt-test/compiler-project/dotty-compiler-plugin/project/plugins.sbt @@ -1 +1 @@ -addSbtPlugin("ch.epfl.lamp" % "sbt-dotty" % "0.2.0") +addSbtPlugin("ch.epfl.lamp" % "sbt-dotty" % "0.2.6") diff --git a/sbt/src/sbt-test/compiler-project/error-in-invalidated/build.sbt b/sbt/src/sbt-test/compiler-project/error-in-invalidated/build.sbt index d2c47e0c4..f49a6898e 100644 --- a/sbt/src/sbt-test/compiler-project/error-in-invalidated/build.sbt +++ b/sbt/src/sbt-test/compiler-project/error-in-invalidated/build.sbt @@ -1,5 +1,6 @@ +ThisBuild / scalaVersion := "2.12.8" + lazy val root = (project in file(".")). settings( - incOptions := xsbti.compile.IncOptions.of(), - scalaVersion := "2.11.7" + incOptions := xsbti.compile.IncOptions.of() ) diff --git a/sbt/src/sbt-test/compiler-project/separate-analysis-per-scala/build.sbt b/sbt/src/sbt-test/compiler-project/separate-analysis-per-scala/build.sbt index d1a4804b7..908667853 100644 --- a/sbt/src/sbt-test/compiler-project/separate-analysis-per-scala/build.sbt +++ b/sbt/src/sbt-test/compiler-project/separate-analysis-per-scala/build.sbt @@ -1,12 +1,15 @@ -name := "foo" +lazy val scala212 = "2.12.8" +lazy val scala213 = "2.13.0-M5" +ThisBuild / scalaVersion := scala212 -scalaVersion := "2.10.6" - -crossScalaVersions := List("2.10.6", "2.11.8") - -incOptions := incOptions.value.withClassfileManagerType( - Option(xsbti.compile.TransactionalManagerType.of( - crossTarget.value / "classes.bak", - (streams in (Compile, compile)).value.log - ): xsbti.compile.ClassFileManagerType).asJava -) +lazy val root = (project in file(".")) + .settings( + name := "foo", + crossScalaVersions := List(scala212, scala213), + incOptions := incOptions.value.withClassfileManagerType( + Option(xsbti.compile.TransactionalManagerType.of( + crossTarget.value / "classes.bak", + (streams in (Compile, compile)).value.log + ): xsbti.compile.ClassFileManagerType).asJava + ) + ) diff --git a/sbt/src/sbt-test/compiler-project/separate-analysis-per-scala/test b/sbt/src/sbt-test/compiler-project/separate-analysis-per-scala/test index e76fa4b5c..10391d966 100644 --- a/sbt/src/sbt-test/compiler-project/separate-analysis-per-scala/test +++ b/sbt/src/sbt-test/compiler-project/separate-analysis-per-scala/test @@ -1,3 +1,3 @@ > + compile -$ exists target/scala-2.10 -$ exists target/scala-2.11 +$ exists target/scala-2.12 +$ exists target/scala-2.13.0-M5 diff --git a/sbt/src/sbt-test/dependency-management/cache-classifiers/multi.sbt b/sbt/src/sbt-test/dependency-management/cache-classifiers/multi.sbt index fa7e3360f..75e55de1d 100644 --- a/sbt/src/sbt-test/dependency-management/cache-classifiers/multi.sbt +++ b/sbt/src/sbt-test/dependency-management/cache-classifiers/multi.sbt @@ -1,10 +1,11 @@ +ThisBuild / scalaVersion := "2.12.8" + def localCache = ivyPaths := IvyPaths(baseDirectory.value, Some((baseDirectory in ThisBuild).value / "ivy" / "cache")) val b = project .settings( localCache, - scalaVersion := "2.11.8", libraryDependencies += "org.example" %% "artifacta" % "1.0.0-SNAPSHOT" withSources() classifier("tests"), externalResolvers := Vector( MavenCache("demo", ((baseDirectory in ThisBuild).value / "demo-repo")), @@ -15,7 +16,6 @@ val b = project val a = project .settings( localCache, - scalaVersion := "2.11.8", organization := "org.example", name := "artifacta", version := "1.0.0-SNAPSHOT", diff --git a/sbt/src/sbt-test/dependency-management/snapshot-resolution/build.sbt b/sbt/src/sbt-test/dependency-management/snapshot-resolution/build.sbt index 31db52a0f..b7d912223 100644 --- a/sbt/src/sbt-test/dependency-management/snapshot-resolution/build.sbt +++ b/sbt/src/sbt-test/dependency-management/snapshot-resolution/build.sbt @@ -1,3 +1,6 @@ +ThisBuild / organization := "com.example" +ThisBuild / scalaVersion := "2.12.8" + def customIvyPaths: Seq[Def.Setting[_]] = Seq( ivyPaths := IvyPaths((baseDirectory in ThisBuild).value, Some((baseDirectory in ThisBuild).value / "ivy-cache")) ) @@ -9,10 +12,9 @@ lazy val sharedResolver: Resolver = { //Resolver.file("example-shared-repo", repoDir)(Resolver.defaultPatterns) } -lazy val common = project. - settings(customIvyPaths: _*). - settings( - scalaVersion := "2.11.8", +lazy val common = project + .settings(customIvyPaths) + .settings( organization := "com.badexample", name := "badexample", version := "1.0-SNAPSHOT", @@ -27,10 +29,9 @@ lazy val common = project. // updateOptions := updateOptions.value.withLatestSnapshots(true) ) -lazy val dependent = project. - settings(customIvyPaths: _*). - settings( - scalaVersion := "2.11.8", +lazy val dependent = project + .settings(customIvyPaths) + .settings( // Uncomment the following to test the before/after // updateOptions := updateOptions.value.withLatestSnapshots(false), // Ignore the inter-project resolver, so we force to look remotely. diff --git a/sbt/src/sbt-test/project/aggregate/projA/build.sbt b/sbt/src/sbt-test/project/aggregate/projA/build.sbt index 88a866ee1..e7bb6bff5 100644 --- a/sbt/src/sbt-test/project/aggregate/projA/build.sbt +++ b/sbt/src/sbt-test/project/aggregate/projA/build.sbt @@ -1,3 +1,3 @@ name := "projA" -scalaVersion := "2.11.8" +scalaVersion := "2.12.8" diff --git a/sbt/src/sbt-test/project/aggregate/test b/sbt/src/sbt-test/project/aggregate/test index 1cb4f2bba..e7243130f 100644 --- a/sbt/src/sbt-test/project/aggregate/test +++ b/sbt/src/sbt-test/project/aggregate/test @@ -1,2 +1,2 @@ > compile -$ exists projA/target/scala-2.11/classes/A.class +$ exists projA/target/scala-2.12/classes/A.class diff --git a/sbt/src/sbt-test/project/flatten/build.sbt b/sbt/src/sbt-test/project/flatten/build.sbt index bbe93fbcc..bab2c5efd 100644 --- a/sbt/src/sbt-test/project/flatten/build.sbt +++ b/sbt/src/sbt-test/project/flatten/build.sbt @@ -1,26 +1,23 @@ -lazy val root = (project in file(".")). - settings( +val unpackage = TaskKey[Unit]("unpackage") + +ThisBuild / scalaVersion := "2.12.8" + +lazy val root = (project in file(".")) + .settings( forConfig(Compile, "src"), forConfig(Test, "test-src"), - baseSettings + libraryDependencies += "org.scalacheck" %% "scalacheck" % "1.14.0" % Test, + unmanagedSources / includeFilter := "*.java" | "*.scala" ) -def baseSettings = Seq( - scalaVersion := "2.11.8", - libraryDependencies += "org.scalacheck" %% "scalacheck" % "1.11.4" % Test, - includeFilter in unmanagedSources := "*.java" | "*.scala" -) - def forConfig(conf: Configuration, name: String) = Project.inConfig(conf)( unpackageSettings(name) ) def unpackageSettings(name: String) = Seq( unmanagedSourceDirectories := (baseDirectory.value / name) :: Nil, - excludeFilter in unmanagedResources := (includeFilter in unmanagedSources).value, + unmanagedResources / excludeFilter := (unmanagedSources / includeFilter).value, unmanagedResourceDirectories := unmanagedSourceDirectories.value, unpackage := { - IO.unzip(artifactPath in packageSrc value, baseDirectory.value / name) + IO.unzip((packageSrc / artifactPath).value, baseDirectory.value / name) IO.delete(baseDirectory.value / name / "META-INF") } ) - -val unpackage = TaskKey[Unit]("unpackage") diff --git a/sbt/src/sbt-test/project/internal-tracking/build.sbt b/sbt/src/sbt-test/project/internal-tracking/build.sbt index ca1ba256c..8374bcaef 100644 --- a/sbt/src/sbt-test/project/internal-tracking/build.sbt +++ b/sbt/src/sbt-test/project/internal-tracking/build.sbt @@ -1,25 +1,21 @@ -lazy val root = (project in file(".")). - aggregate(a, b, c, d). - settings( - inThisBuild(Seq( - scalaVersion := "2.11.7", - trackInternalDependencies := TrackLevel.NoTracking - )) - ) +ThisBuild / scalaVersion := "2.12.8" +ThisBuild / trackInternalDependencies := TrackLevel.NoTracking + +lazy val root = (project in file(".")) + .aggregate(a, b, c, d) lazy val a = (project in file("a")) -lazy val b = (project in file("b")). - dependsOn(a) +lazy val b = (project in file("b")) + .dependsOn(a) -lazy val c = (project in file("c")). - settings( +lazy val c = (project in file("c")) + .settings( exportToInternal := TrackLevel.NoTracking ) -lazy val d = (project in file("d")). - dependsOn(c). - settings( +lazy val d = (project in file("d")) + .dependsOn(c) + .settings( trackInternalDependencies := TrackLevel.TrackIfMissing ) -