In a multi-project build, say you have project project-a
that publishes on Maven with artifactId = "my-super-cool-project-a"
like:
tasks {
named<AbstractMavenPublication>("myPub") {
artifactId = "my-super-cool-project-a"
}
}
// OR
publishing {
publications {
named<MavenPublication>("myPub") {
artifactId = "my-super-cool-project-a"
}
}
}
Then in your project-b
you import it in the transitive Java/Kotlin configuration:
dependencies {
api(project(":project-a"))
}
You then publish project-b
on Maven as well. Will project-b
pom
and/or Gradle Metadata
know that the transitive dependency of project-a
has the artifactId
of my-super-cool-project-a
?
My guess is that when using the publishing.publication
extensions the published metadata will be correct.