Skip to content

Commit

Permalink
Specify namespace to add in package
Browse files Browse the repository at this point in the history
  • Loading branch information
louptheron committed Oct 18, 2023
1 parent 461fba8 commit e60c406
Showing 1 changed file with 6 additions and 14 deletions.
20 changes: 6 additions & 14 deletions backend/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -86,19 +86,13 @@ description = "MonitorEnv"
java.sourceCompatibility = JavaVersion.VERSION_17

sourceSets {
create("apiSupport") {
create("publicApi") {
java {
srcDir("src/main/kotlin/fr/gouv/cacem/monitorenv/infrastructure")
srcDir("src/main/kotlin/fr/gouv/cacem/monitorenv/infrastructure/api/adapters/publicapi")
}
}
}

java {
registerFeature("apiSupport") {
usingSourceSet(sourceSets["apiSupport"])
}
}

// This publication is only runned from the CI in Github Actions
publishing {
repositories {
Expand All @@ -112,18 +106,16 @@ publishing {
}
}
publications {
val apiSourceJar by tasks.registering(Jar::class) {
from(sourceSets["apiSupport"].allSource)
val publicApiSourceJar by tasks.registering(Jar::class) {
from(sourceSets["publicApi"].allSource)
}

register<MavenPublication>("gpr") {
groupId = "fr.gouv.monitor"
artifactId = "api"
version = "v0.0.2"
version = "VERSION_TO_CHANGE"

// from(components["apiSupport"])
artifact(apiSourceJar.get())
// exclude(listOf("**/domain/**"))
artifact(publicApiSourceJar.get())
}
}
}
Expand Down

0 comments on commit e60c406

Please sign in to comment.