@@ -10,6 +10,7 @@ import complete.DefaultParsers._
1010import pl .project13 .scala .sbt .JmhPlugin
1111import pl .project13 .scala .sbt .JmhPlugin .JmhKeys .Jmh
1212import sbt .Package .ManifestAttributes
13+ import sbt .plugins .SbtPlugin
1314import sbt .ScriptedPlugin .autoImport ._
1415import xerial .sbt .pack .PackPlugin
1516import xerial .sbt .pack .PackPlugin .autoImport ._
@@ -356,7 +357,6 @@ object Build {
356357 lazy val `dotty-bootstrapped` = project.asDottyRoot(Bootstrapped )
357358
358359 lazy val `dotty-interfaces` = project.in(file(" interfaces" )).
359- disablePlugins(ScriptedPlugin ).
360360 settings(commonScala2Settings). // Java-only project, so this is fine
361361 settings(
362362 // Do not append Scala versions to the generated artifacts
@@ -530,7 +530,7 @@ object Build {
530530 // FIXME: Not needed, but should be on the compiler CP
531531 (" org.scala-lang.modules" %% " scala-xml" % " 1.1.0" ).withDottyCompat(scalaVersion.value),
532532 " org.scala-lang" % " scala-library" % scalacVersion % " test" ,
533- Dependencies .compilerInterface(sbtVersion.value) ,
533+ Dependencies .`compiler-interface` ,
534534 " org.jline" % " jline-reader" % " 3.9.0" , // used by the REPL
535535 " org.jline" % " jline-terminal" % " 3.9.0" ,
536536 " org.jline" % " jline-terminal-jna" % " 3.9.0" // needed for Windows
@@ -799,8 +799,8 @@ object Build {
799799 description := " sbt compiler bridge for Dotty" ,
800800 resolvers += Resolver .typesafeIvyRepo(" releases" ), // For org.scala-sbt:api
801801 libraryDependencies ++= Seq (
802- Dependencies .compilerInterface(sbtVersion.value) % Provided ,
803- (Dependencies .zincApiinfo(sbtVersion.value) % Test ).withDottyCompat(scalaVersion.value)
802+ Dependencies .`compiler-interface` % Provided ,
803+ (Dependencies .`zinc-api-info` % Test ).withDottyCompat(scalaVersion.value)
804804 ),
805805 // The sources should be published with crossPaths := false since they
806806 // need to be compiled by the project using the bridge.
@@ -893,7 +893,7 @@ object Build {
893893 buildInfoPackage in Test := " dotty.tools.languageserver.util.server" ,
894894 BuildInfoPlugin .buildInfoScopedSettings(Test ),
895895 BuildInfoPlugin .buildInfoDefaultSettings
896- ).disablePlugins( ScriptedPlugin )
896+ )
897897
898898 lazy val `dotty-bench` = project.in(file(" bench" )).asDottyBench(NonBootstrapped )
899899 lazy val `dotty-bench-bootstrapped` = project.in(file(" bench" )).asDottyBench(Bootstrapped )
@@ -928,6 +928,7 @@ object Build {
928928 // sbt plugin to use Dotty in your own build, see
929929 // https://github.com/lampepfl/dotty-example-project for usage.
930930 lazy val `sbt-dotty` = project.in(file(" sbt-dotty" )).
931+ enablePlugins(SbtPlugin ).
931932 settings(commonSettings).
932933 settings(
933934 version := {
@@ -938,11 +939,10 @@ object Build {
938939 // Keep in sync with inject-sbt-dotty.sbt
939940 libraryDependencies ++= Seq (
940941 Dependencies .`jackson-databind`,
941- Dependencies .compilerInterface(sbtVersion.value)
942+ Dependencies .`compiler-interface`
942943 ),
943944 unmanagedSourceDirectories in Compile +=
944945 baseDirectory.value / " ../language-server/src/dotty/tools/languageserver/config" ,
945- sbtPlugin := true ,
946946 sbtTestDirectory := baseDirectory.value / " sbt-test" ,
947947 scriptedLaunchOpts ++= Seq (
948948 " -Dplugin.version=" + version.value,
@@ -1253,7 +1253,6 @@ object Build {
12531253
12541254 // FIXME: we do not aggregate `bin` because its tests delete jars, thus breaking other tests
12551255 def asDottyRoot (implicit mode : Mode ): Project = project.withCommonSettings.
1256- disablePlugins(ScriptedPlugin ).
12571256 aggregate(`dotty-interfaces`, dottyLibrary, dottyCompiler, dottyDoc, dottySbtBridgeReference).
12581257 bootstrappedAggregate(`scala-library`, `scala-compiler`, `scala-reflect`, scalap, `dotty-language-server`).
12591258 dependsOn(dottyCompiler).
@@ -1263,38 +1262,32 @@ object Build {
12631262 )
12641263
12651264 def asDottyCompiler (implicit mode : Mode ): Project = project.withCommonSettings.
1266- disablePlugins(ScriptedPlugin ).
12671265 dependsOn(`dotty-interfaces`).
12681266 dependsOn(dottyLibrary).
12691267 settings(dottyCompilerSettings)
12701268
12711269 def asDottyLibrary (implicit mode : Mode ): Project = project.withCommonSettings.
1272- disablePlugins(ScriptedPlugin ).
12731270 settings(dottyLibrarySettings).
12741271 bootstrappedSettings(
12751272 // Needed so that the library sources are visible when `dotty.tools.dotc.core.Definitions#init` is called.
12761273 scalacOptions in Compile ++= Seq (" -sourcepath" , (scalaSource in Compile ).value.getAbsolutePath)
12771274 )
12781275
12791276 def asDottyDoc (implicit mode : Mode ): Project = project.withCommonSettings.
1280- disablePlugins(ScriptedPlugin ).
12811277 dependsOn(dottyCompiler, dottyCompiler % " test->test" ).
12821278 settings(dottyDocSettings)
12831279
12841280 def asDottySbtBridge (implicit mode : Mode ): Project = project.withCommonSettings.
1285- disablePlugins(ScriptedPlugin ).
12861281 dependsOn(dottyCompiler % Provided ).
12871282 dependsOn(dottyDoc % Provided ).
12881283 settings(dottySbtBridgeSettings)
12891284
12901285 def asDottyBench (implicit mode : Mode ): Project = project.withCommonSettings.
1291- disablePlugins(ScriptedPlugin ).
12921286 dependsOn(dottyCompiler).
12931287 settings(commonBenchmarkSettings).
12941288 enablePlugins(JmhPlugin )
12951289
12961290 def asDist (implicit mode : Mode ): Project = project.
1297- disablePlugins(ScriptedPlugin ).
12981291 enablePlugins(PackPlugin ).
12991292 withCommonSettings.
13001293 dependsOn(`dotty-interfaces`, dottyCompiler, dottyLibrary, dottyDoc).
0 commit comments