Skip to content

Commit

Permalink
Fix automatic module name
Browse files Browse the repository at this point in the history
which can't have `-`, so replace with `.`
  • Loading branch information
big-andy-coates committed Feb 2, 2024
1 parent c514196 commit 0af7e62
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 deletions.
8 changes: 4 additions & 4 deletions buildSrc/src/main/kotlin/creek-coverage-convention.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@
/**
* Standard coverage configuration of Creek projects, utilising Jacoco and Coveralls.io
*
* <p>Version: 1.2
*
* <p>Apply to root project only
* <p>Versions:
* - 1.3: remove deprecated use of $buildDir
* - 1.2: Apply to root project only
*/

plugins {
Expand Down Expand Up @@ -64,7 +64,7 @@ val coverage = tasks.register<JacocoReport>("coverage") {

coveralls {
sourceDirs = allprojects.flatMap{it.sourceSets.main.get().allSource.srcDirs}.map{it.toString()}
jacocoReportPath = "$buildDir/reports/jacoco/coverage/coverage.xml"
jacocoReportPath = layout.buildDirectory.file("reports/jacoco/coverage/coverage.xml")
}

tasks.coveralls {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@
/**
* Configuration for Creek Gradle plugin publishing.
*
* <p>Version: 1.5
* <p>Versions:
* - 1.6: Correct automatic module name
* - 1.5: Switch to using `gradlePlugin`, as required by Gradle 8.0
* - 1.4: Fix website URL to avoid redirect
* - 1.3: Switch to setting 'system' from issue-management
Expand Down Expand Up @@ -66,9 +67,9 @@ tasks.javadoc {
tasks.jar {
manifest {
if (prependRootName) {
attributes("Automatic-Module-Name" to "${rootProject.name}-${project.name}")
attributes("Automatic-Module-Name" to "${rootProject.name}-${project.name}".replace("-", "."))
} else {
attributes("Automatic-Module-Name" to project.name)
attributes("Automatic-Module-Name" to project.name.replace("-", "."))
}
}
}
Expand Down

0 comments on commit 0af7e62

Please sign in to comment.