Closed joffrey-bion closed 1 month ago
For name
it's because they are different. The POM name is supposed to be a human readable name while Gradle's project.name
is usually just the directory name. In multi module projects name
could also be duplicated because you :foo:a
and :bar:a
both have a
as name. So I don't think it's a good default.
For the description
, too be honest I didn't even know it existed and I haven't seen it used before. It would work but for consistency I think it's better to just leave it as is.
The pom's name
is not clearly defined, indeed. That doesn't mean it has to be different from the artifact id though (which is set to the project name by default AFAIK).
Maven Central guidelines mention that an acceptable practice is to use groupId:artifactId
as name. Could this be a more reasonable default in your opinion?
https://central.sonatype.org/publish/requirements/#project-name-description-and-url
Do you foresee any issue with the description
defaulting to the project description? You said "for consistency", you mean consistency with what?
Fun fact: on mavenrepository.com's artifact page the artifact ID that I put in the name is actually split by words and capitalized 😆
The pom for this one: https://repo1.maven.org/maven2/org/hildan/krossbow/krossbow-websocket-core/7.3.0/krossbow-websocket-core-7.3.0.pom
The Gradle
Project
type already has aname
anddescription
that we can set for various purposes.Couldn't we use them as default values for the POM's
name
anddescription
fields?There is a clear benefit because those fields are required by Maven Central, so it would be 2 lines of boilerplate gone.