-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle.kts
100 lines (90 loc) · 3.91 KB
/
build.gradle.kts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
plugins {
id("io.github.gradle-nexus.publish-plugin") version "2.0.0"
`maven-publish`
`signing`
}
val artifactIds = mapOf(
"ovhcloud-s3-control-plane" to "control-plane-s3",
"ovhcloud-s3-core" to "core-s3",
"ovhcloud-s3-data-plane" to "data-plane-s3"
)
val v = System.getenv("EDC_EXTENSIONS_VERSION")
val u = System.getenv("OSSRH_USERNAME")
val p = System.getenv("OSSRH_PASSWORD")
val h = System.getenv("OSSRH_HOSTNAME")
val signingKey = System.getenv("SIGNING_KEY")
val signingKeyPassphrase = System.getenv("SIGNING_KEY_PASSPHRASE")
group = "com.ovhcloud.edc"
subprojects {
apply(plugin = "maven-publish")
apply(plugin = "java")
apply(plugin = "signing")
if (name in listOf("ovhcloud-s3-control-plane","ovhcloud-s3-data-plane","ovhcloud-s3-core")) {
publishing {
publications {
create<MavenPublication>("${project.name}") {
groupId = "com.ovhcloud.edc"
artifactId = artifactIds[project.name] ?: project.name
version = v
from(components["java"])
pom {
name.set("${artifactId}")
description.set("Eclipse Dataspace Connector (EDC) extension component: ${artifactId}")
url.set("https://projects.eclipse.org/projects/technology.edc")
licenses {
license {
name.set("The Apache License, Version 2.0")
url.set("http://www.apache.org/licenses/LICENSE-2.0.txt")
}
}
developers {
developer {
name.set("Olivier Caudron")
email.set("[email protected]")
organization.set("OVHcloud")
organizationUrl.set("https://www.ovhcloud.com")
}
developer {
name.set("David Drugeon-Hamon")
email.set("[email protected]")
organization.set("wescale")
organizationUrl.set("https://www.wescale.fr/")
}
developer {
name.set("Jean-Raymond Sue")
email.set("[email protected]")
organization.set("OVHcloud")
organizationUrl.set("https://www.ovhcloud.com")
}
developer {
name.set("Pierre-Henri Symoneaux")
email.set("[email protected]")
organization.set("OVHcloud")
organizationUrl.set("https://www.ovhcloud.com")
}
}
scm {
connection.set("scm:git:[email protected]:ovh/edc-ovhcloud-s3.git")
developerConnection.set("scm:git:ssh://github.com:ovh/edc-ovhcloud-s3.git")
url.set("https://github.com/ovh/edc-ovhcloud-s3/tree/main")
}
}
}
}
}
signing {
useInMemoryPgpKeys(signingKey, signingKeyPassphrase)
sign(publishing.publications["${project.name}"])
}
}
}
nexusPublishing {
repositories {
sonatype {
nexusUrl.set(uri("https://${h}/service/local/"))
snapshotRepositoryUrl.set(uri("https://${h}/content/repositories/snapshots/"))
username.set(u)
password.set(p)
}
}
}