Adopt PR feedbacks

This commit is contained in:
Friendseeker 2024-10-25 11:15:24 -07:00 committed by friendseeker
parent 824395f6be
commit 4beb78b260
No known key found for this signature in database
GPG Key ID: 7DD5039728A27160
2 changed files with 11 additions and 4 deletions

View File

@ -178,8 +178,7 @@ def mimaSettingsSince(versions: Seq[String]): Seq[Def.Setting[_]] = Def settings
exclude[DirectMissingMethodProblem]("sbt.PluginData.this"),
exclude[IncompatibleResultTypeProblem]("sbt.EvaluateTask.executeProgress"),
exclude[DirectMissingMethodProblem]("sbt.Keys.currentTaskProgress"),
exclude[IncompatibleResultTypeProblem]("sbt.PluginData.copy$default$10"),
exclude[DirectMissingMethodProblem]("sbt.Defaults.configArtifactPathSetting"),
exclude[IncompatibleResultTypeProblem]("sbt.PluginData.copy$default$10")
),
)

View File

@ -647,8 +647,7 @@ object Defaults extends BuildCommon {
val dir = classDirectory.value
converter.toVirtualFile(dir.toPath)
},
earlyOutput / artifactPath := crossTarget.value /
(prefix(configuration.value.name) + "early") / "early.jar",
earlyOutput / artifactPath := configArtifactPathSetting(artifact, "early").value,
earlyOutput := {
val converter = fileConverter.value
val jar = (earlyOutput / artifactPath).value
@ -1814,6 +1813,15 @@ object Defaults extends BuildCommon {
excludes: ScopedTaskable[FileFilter]
): Initialize[Task[Seq[File]]] = collectFiles(dirs: Taskable[Seq[File]], filter, excludes)
private[sbt] def configArtifactPathSetting(
art: SettingKey[Artifact],
extraPrefix: String
): Initialize[File] =
Def.setting {
crossTarget.value /
(prefix(configuration.value.name) + "early") / "early.jar"
}
private[sbt] def prefixArtifactPathSetting(
art: SettingKey[Artifact],
extraPrefix: String