From 0d32f6fc76eb2b2264b70285110c0183ebc8fcb9 Mon Sep 17 00:00:00 2001 From: Dale Wijnand Date: Tue, 11 Apr 2017 13:28:54 +0100 Subject: [PATCH] Drop File/Seq[File] setting enrichments --- .../src/main/scala/sbt/Structure.scala | 27 ------------------- .../ivy-settings-multi-b/build.sbt | 2 +- 2 files changed, 1 insertion(+), 28 deletions(-) diff --git a/main-settings/src/main/scala/sbt/Structure.scala b/main-settings/src/main/scala/sbt/Structure.scala index 3ba91e834..68dfdb987 100644 --- a/main-settings/src/main/scala/sbt/Structure.scala +++ b/main-settings/src/main/scala/sbt/Structure.scala @@ -5,10 +5,6 @@ package sbt import scala.language.experimental.macros -import java.io.File - -import sbt.io.{ FileFilter, PathFinder } -import sbt.io.syntax._ import sbt.internal.util.Types._ import sbt.internal.util.{ ~>, AList, AttributeKey, Settings, SourcePosition } import sbt.util.OptJsonWriter @@ -271,29 +267,6 @@ object Scoped { def dependOn: Initialize[Task[Unit]] = Initialize.joinAny[Task](keys).apply(deps => nop.dependsOn(deps: _*)) } - implicit def richFileSetting(s: SettingKey[File]): RichFileSetting = new RichFileSetting(s) - implicit def richFilesSetting(s: SettingKey[Seq[File]]): RichFilesSetting = new RichFilesSetting(s) - - final class RichFileSetting(s: SettingKey[File]) extends RichFileBase { - @deprecated("Use a standard setting definition.", "0.13.0") - def /(c: String): Initialize[File] = s { _ / c } - protected[this] def map0(f: PathFinder => PathFinder) = s(file => finder(f)(file :: Nil)) - } - final class RichFilesSetting(s: SettingKey[Seq[File]]) extends RichFileBase { - @deprecated("Use a standard setting definition.", "0.13.0") - def /(s: String): Initialize[Seq[File]] = map0 { _ / s } - protected[this] def map0(f: PathFinder => PathFinder) = s(finder(f)) - } - sealed abstract class RichFileBase { - @deprecated("Use a standard setting definition.", "0.13.0") - def *(filter: FileFilter): Initialize[Seq[File]] = map0 { _ * filter } - @deprecated("Use a standard setting definition.", "0.13.0") - def **(filter: FileFilter): Initialize[Seq[File]] = map0 { _ ** filter } - protected[this] def map0(f: PathFinder => PathFinder): Initialize[Seq[File]] - protected[this] def finder(f: PathFinder => PathFinder): Seq[File] => Seq[File] = - in => f(in).get - } - // this is the least painful arrangement I came up with @deprecated("The sbt 0.10 style DSL is deprecated: '(k1, k2) map { (x, y) => ... }' should now be '{ val x = k1.value; val y = k2.value }'.\nSee http://www.scala-sbt.org/0.13/docs/Migrating-from-sbt-012x.html", "0.13.13") implicit def t2ToTable2[A, B](t2: (ScopedTaskable[A], ScopedTaskable[B])): RichTaskable2[A, B] = new RichTaskable2(t2) @deprecated("The sbt 0.10 style DSL is deprecated: '(k1, k2) map { (x, y) => ... }' should now be '{ val x = k1.value; val y = k2.value }'.\nSee http://www.scala-sbt.org/0.13/docs/Migrating-from-sbt-012x.html", "0.13.13") implicit def t3ToTable3[A, B, C](t3: (ScopedTaskable[A], ScopedTaskable[B], ScopedTaskable[C])): RichTaskable3[A, B, C] = new RichTaskable3(t3) diff --git a/sbt/src/sbt-test/dependency-management/ivy-settings-multi-b/build.sbt b/sbt/src/sbt-test/dependency-management/ivy-settings-multi-b/build.sbt index 8a7846582..0718f9071 100644 --- a/sbt/src/sbt-test/dependency-management/ivy-settings-multi-b/build.sbt +++ b/sbt/src/sbt-test/dependency-management/ivy-settings-multi-b/build.sbt @@ -2,4 +2,4 @@ lazy val a = (project in file(".")). settings(externalIvySettings()) dependsOn(b) lazy val b = (project in file("b")). - settings(externalIvySettings( (baseDirectory in ThisBuild) / "ivysettings.xml" )) + settings(externalIvySettings( Def setting ((baseDirectory in ThisBuild).value / "ivysettings.xml") ))