Skip to content

Commit 0b332a7

Browse files
committed
Skip jitpack builds of dp-inntekt-api
added pom info for dp-inntekt-grpc navik/dagpenger#406
1 parent 403345c commit 0b332a7

File tree

2 files changed

+52
-1
lines changed

2 files changed

+52
-1
lines changed

dp-inntekt-grpc/build.gradle.kts

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -104,3 +104,48 @@ sourceSets {
104104
}
105105
}
106106
}
107+
108+
val artifactDescription = "dp-inntekt-grpc - gRPC client for fetching inntekt in Dagpenger context"
109+
val repoUrl = "https://github.com/navikt/dp-inntekt.git"
110+
val scmUrl = "scm:git:https://github.com/navikt/dp-inntekt.git"
111+
112+
val sourcesJar by tasks.registering(Jar::class) {
113+
archiveClassifier.set("sources")
114+
from(sourceSets["main"].allSource)
115+
}
116+
117+
publishing {
118+
publications {
119+
create<MavenPublication>("maven") {
120+
from(components["java"])
121+
artifact(sourcesJar.get())
122+
123+
pom {
124+
description.set(artifactDescription)
125+
name.set(project.name)
126+
url.set(repoUrl)
127+
withXml {
128+
asNode().appendNode("packaging", "jar")
129+
}
130+
licenses {
131+
license {
132+
name.set("MIT License")
133+
name.set("https://opensource.org/licenses/MIT")
134+
}
135+
}
136+
developers {
137+
developer {
138+
organization.set("NAV (Arbeids- og velferdsdirektoratet) - The Norwegian Labour and Welfare Administration")
139+
organizationUrl.set("https://www.nav.no")
140+
}
141+
}
142+
143+
scm {
144+
connection.set(scmUrl)
145+
developerConnection.set(scmUrl)
146+
url.set(repoUrl)
147+
}
148+
}
149+
}
150+
}
151+
}

settings.gradle.kts

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,10 @@
88
*/
99

1010
rootProject.name = "dp-inntekt"
11-
include("dp-inntekt-api", "dp-inntekt-grpc")
11+
include("dp-inntekt-grpc")
12+
13+
var jitpack: Boolean = System.getenv("JITPACK")?.toBoolean() ?: false
14+
15+
if (!jitpack) { // skip jitpack build of dp-inntekt-api
16+
include("dp-inntekt-api")
17+
}

0 commit comments

Comments
 (0)