[2.x] Update project/PublishBinPlugin.scala (#8498)

avoid useCoursier. prepare sbt 2
This commit is contained in:
kenji yoshida 2026-01-13 06:20:23 +09:00 committed by GitHub
parent ebc11f04a7
commit f31290b809
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 7 additions and 13 deletions

View File

@ -35,19 +35,13 @@ object PublishBinPlugin extends AutoPlugin {
publishLocalBinConfig := publishLocalBinConfig
.dependsOn(
// Copied from sbt.internal.
Def.taskDyn {
val doGen = useCoursier.value
if (doGen)
Def.task {
val currentProject = {
val proj = csrProject.value
val publications = csrPublications.value
proj.withPublications(publications)
}
IvyXml.writeFiles(currentProject, None, ivySbt.value, streams.value.log)
}
else
Def.task(())
Def.task {
val currentProject = {
val proj = csrProject.value
val publications = csrPublications.value
proj.withPublications(publications)
}
IvyXml.writeFiles(currentProject, None, ivySbt.value, streams.value.log)
}
)
.value,