Skip to content

Commit

Permalink
Rename millImport variable to metaBuild (#3848)
Browse files Browse the repository at this point in the history
We have various things to import, but this parameter is for the
enabled-state of the meta-build, so reflect it in the name.

Pull request: #3848
  • Loading branch information
lefou authored Oct 29, 2024
1 parent 345f5a5 commit ad9ff0a
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions runner/src/mill/runner/FileImportGraph.scala
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,15 @@ import scala.collection.mutable
* @param ivyDeps
* @param importGraphEdges
* @param errors
* @param millImport If `true`, a meta-build is enabled
* @param metaBuild If `true`, a meta-build is enabled
*/
@internal
case class FileImportGraph(
seenScripts: Map[os.Path, String],
repos: Seq[(String, os.Path)],
ivyDeps: Set[String],
errors: Seq[String],
millImport: Boolean,
metaBuild: Boolean,
buildFile: String
)

Expand Down
2 changes: 1 addition & 1 deletion runner/src/mill/runner/MillBuildBootstrap.scala
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ class MillBuildBootstrap(
output
)

if (parsedScriptFiles.millImport) evaluateRec(depth + 1)
if (parsedScriptFiles.metaBuild) evaluateRec(depth + 1)
else {
val bootstrapModule =
new MillBuildRootModule.BootstrapModule()(
Expand Down
4 changes: 2 additions & 2 deletions runner/src/mill/runner/MillBuildRootModule.scala
Original file line number Diff line number Diff line change
Expand Up @@ -193,13 +193,13 @@ abstract class MillBuildRootModule()(implicit

override def sources: T[Seq[PathRef]] = Task {
scriptSources() ++ {
if (parseBuildFiles().millImport) super.sources()
if (parseBuildFiles().metaBuild) super.sources()
else Seq.empty[PathRef]
}
}

override def resources: T[Seq[PathRef]] = Task {
if (parseBuildFiles().millImport) super.resources()
if (parseBuildFiles().metaBuild) super.resources()
else Seq.empty[PathRef]
}

Expand Down

0 comments on commit ad9ff0a

Please sign in to comment.