mirror of
https://github.com/xpipe-io/xpipe.git
synced 2024-11-22 07:30:24 +00:00
41 lines
No EOL
1.1 KiB
Groovy
41 lines
No EOL
1.1 KiB
Groovy
java {
|
|
withJavadocJar()
|
|
withSourcesJar()
|
|
}
|
|
|
|
def repoUrl = !rootProject.isFullRelease ? 'https://s01.oss.sonatype.org/content/repositories/snapshots/'
|
|
: 'https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/'
|
|
def user = project.hasProperty('sonatypeUsername') ? project.property('sonatypeUsername') : System.getenv('SONATYPE_USERNAME')
|
|
def pass = project.hasProperty('sonatypePassword') ? project.property('sonatypePassword') : System.getenv('SONATYPE_PASSWORD')
|
|
|
|
if (rootProject.isFullRelease) {
|
|
publish.finalizedBy(rootProject.getTasks().getByName('closeAndReleaseRepository'))
|
|
}
|
|
|
|
tasks.withType(GenerateModuleMetadata) {
|
|
enabled = false
|
|
}
|
|
|
|
publishing {
|
|
repositories {
|
|
maven {
|
|
setUrl repoUrl
|
|
credentials {
|
|
setUsername user
|
|
setPassword pass
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
signing {
|
|
useInMemoryPgpKeys(signingKeyId, signingKey, signingPassword)
|
|
sign publishing.publications.mavenJava
|
|
}
|
|
|
|
nexusStaging {
|
|
serverUrl = "https://s01.oss.sonatype.org/service/local/"
|
|
packageGroup = "io.xpipe"
|
|
username = user
|
|
password = pass
|
|
} |