Skip to content

Commit 2a18e12

Browse files
authored
Make the artifact ID explicit rather than relying on implicit naming. (#255)
* Make the artifact ID explicit rather than relying on implicit naming. This allows naming the rootProject whatever we want. Improving developer experience in IDE for example. * Set module name explicitly * Set everything based on a central value.
1 parent b116c25 commit 2a18e12

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

build.gradle.kts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ plugins {
1515
id("org.ajoberstar.stutter") version "0.7.2"
1616
}
1717

18+
base { archivesName = "publish-plugin" }
1819
group = "io.github.gradle-nexus"
1920
version = "2.0.0-SNAPSHOT"
2021

@@ -266,6 +267,7 @@ publishing {
266267
publications {
267268
afterEvaluate {
268269
named<MavenPublication>("pluginMaven") {
270+
artifactId = base.archivesName.get()
269271
pom {
270272
name = readableName
271273
description = project.description
@@ -292,4 +294,3 @@ publishing {
292294
}
293295
}
294296
}
295-

settings.gradle.kts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,4 @@ gradleEnterprise {
1313
}
1414
}
1515

16-
// this needs to stay this way since it's used as the plugin's artifact id
17-
// for generating the plugin marker
18-
rootProject.name = "publish-plugin"
16+
rootProject.name = "gradle-nexus-publish-plugin"

0 commit comments

Comments
 (0)