From 6bbbaca41a468917a4bf664e3d8ae8f9ca5d25e6 Mon Sep 17 00:00:00 2001 From: Alex Archambault Date: Wed, 11 Dec 2024 15:16:52 +0100 Subject: [PATCH] Rename {all,extra}BomDeps to {all,extra}BomIvyDeps --- build.mill | 2 +- scalalib/src/mill/scalalib/JavaModule.scala | 16 ++++++++-------- scalalib/src/mill/scalalib/PublishModule.scala | 4 ++-- 3 files changed, 11 insertions(+), 11 deletions(-) diff --git a/build.mill b/build.mill index d55f29dded2..10c082539d8 100644 --- a/build.mill +++ b/build.mill @@ -549,7 +549,7 @@ trait MillStableScalaModule extends MillPublishScalaModule with Mima { "mill.scalalib.JavaModule.mill$scalalib$JavaModule$$super$runMain" ), // Added overrides for a new targets, should be safe - ProblemFilter.exclude[ReversedMissingMethodProblem]("mill.scalalib.JavaModule#JavaModuleTests.mill$scalalib$JavaModule$JavaModuleTests$$super$extraBomDeps"), + ProblemFilter.exclude[ReversedMissingMethodProblem]("mill.scalalib.JavaModule#JavaModuleTests.mill$scalalib$JavaModule$JavaModuleTests$$super$extraBomIvyDeps"), ProblemFilter.exclude[ReversedMissingMethodProblem]("mill.scalalib.JavaModule#JavaModuleTests.mill$scalalib$JavaModule$JavaModuleTests$$super$extraDepManagement"), // Terminal is sealed, not sure why MIMA still complains ProblemFilter.exclude[ReversedMissingMethodProblem]("mill.eval.Terminal.task"), diff --git a/scalalib/src/mill/scalalib/JavaModule.scala b/scalalib/src/mill/scalalib/JavaModule.scala index edb70e0e4f3..cc1873af648 100644 --- a/scalalib/src/mill/scalalib/JavaModule.scala +++ b/scalalib/src/mill/scalalib/JavaModule.scala @@ -57,9 +57,9 @@ trait JavaModule } } - override def extraBomDeps = Task.Anon[Agg[BomDependency]] { - super.extraBomDeps() ++ - outer.allBomDeps().map(_.withConfig(Configuration.test)) + override def extraBomIvyDeps = Task.Anon[Agg[BomDependency]] { + super.extraBomIvyDeps() ++ + outer.allBomIvyDeps().map(_.withConfig(Configuration.test)) } override def extraDepManagement = Task.Anon[Agg[Dep]] { super.extraDepManagement() ++ @@ -174,7 +174,7 @@ trait JavaModule */ def bomIvyDeps: T[Agg[Dep]] = Task { Agg.empty[Dep] } - def allBomDeps: Task[Agg[BomDependency]] = Task.Anon { + def allBomIvyDeps: Task[Agg[BomDependency]] = Task.Anon { val modVerOrMalformed = bomIvyDeps().map(bindDependency()).map { bomDep => val fromModVer = coursier.core.Dependency(bomDep.dep.module, bomDep.dep.version) @@ -207,7 +207,7 @@ trait JavaModule * modules, while ensuring test dependencies of the BOM are taken into account too * in the test module. */ - def extraBomDeps: Task[Agg[BomDependency]] = Task.Anon { Agg.empty[BomDependency] } + def extraBomIvyDeps: Task[Agg[BomDependency]] = Task.Anon { Agg.empty[BomDependency] } /** * Dependency management entries that are not meant to be overridden or changed by users. @@ -511,7 +511,7 @@ trait JavaModule overrideVersions: Boolean = false ): Task[coursier.core.Dependency => coursier.core.Dependency] = Task.Anon { val bomDeps0 = - allBomDeps().toSeq.map(_.withConfig(Configuration.compile)) ++ extraBomDeps().toSeq + allBomIvyDeps().toSeq.map(_.withConfig(Configuration.compile)) ++ extraBomIvyDeps().toSeq val depMgmt = processedDependencyManagement( (extraDepManagement().toSeq ++ depManagement().toSeq) .map(bindDependency()) @@ -533,7 +533,7 @@ trait JavaModule def processCompileDependency( overrideVersions: Boolean = false ): Task[coursier.core.Dependency => coursier.core.Dependency] = Task.Anon { - val bomDeps0 = allBomDeps().toSeq.map(_.withConfig(Configuration.provided)) + val bomDeps0 = allBomIvyDeps().toSeq.map(_.withConfig(Configuration.provided)) val depMgmt = processedDependencyManagement( (compileDepManagement().toSeq ++ extraDepManagement().toSeq ++ depManagement().toSeq) .map(bindDependency()) @@ -555,7 +555,7 @@ trait JavaModule def processRunDependency( overrideVersions: Boolean = false ): Task[coursier.core.Dependency => coursier.core.Dependency] = Task.Anon { - val bomDeps0 = allBomDeps().toSeq.map(_.withConfig(Configuration.defaultCompile)) + val bomDeps0 = allBomIvyDeps().toSeq.map(_.withConfig(Configuration.defaultCompile)) val depMgmt = processedDependencyManagement( (runDepManagement().toSeq ++ depManagement()) .map(bindDependency()) diff --git a/scalalib/src/mill/scalalib/PublishModule.scala b/scalalib/src/mill/scalalib/PublishModule.scala index e4f32277f5a..488224587fe 100644 --- a/scalalib/src/mill/scalalib/PublishModule.scala +++ b/scalalib/src/mill/scalalib/PublishModule.scala @@ -146,8 +146,8 @@ trait PublishModule extends JavaModule { outer => val (processedDeps, depMgmt) = defaultResolver().processDeps( processedRunIvyDeps() ++ processedIvyDeps(), resolutionParams = resolutionParams(), - boms = - allBomDeps().toSeq.map(_.withConfig(Configuration.defaultCompile)) ++ extraBomDeps().toSeq + boms = allBomIvyDeps().toSeq.map(_.withConfig(Configuration.defaultCompile)) ++ + extraBomIvyDeps().toSeq ) (processedDeps.map(_.moduleVersion).toMap, depMgmt) }