Add system properties to avoid publishing
This commit is contained in:
parent
8dcf45b8d5
commit
fd046394a4
@ -110,6 +110,8 @@ internal fun Project.addGithubPublishing(
|
|||||||
githubOrg: String,
|
githubOrg: String,
|
||||||
githubProject: String
|
githubProject: String
|
||||||
) {
|
) {
|
||||||
|
if (requestPropertyOrNull("publishing.github") == "false") return
|
||||||
|
|
||||||
val githubUser: String = requestProperty("publishing.github.user")
|
val githubUser: String = requestProperty("publishing.github.user")
|
||||||
val githubToken: String = requestProperty("publishing.github.token")
|
val githubToken: String = requestProperty("publishing.github.token")
|
||||||
|
|
||||||
@ -135,6 +137,8 @@ internal fun Project.addGithubPublishing(
|
|||||||
}
|
}
|
||||||
|
|
||||||
internal fun Project.addSpacePublishing(spaceRepo: String) {
|
internal fun Project.addSpacePublishing(spaceRepo: String) {
|
||||||
|
if (requestPropertyOrNull("publishing.space") == "false") return
|
||||||
|
|
||||||
val spaceUser: String = requestProperty("publishing.space.user")
|
val spaceUser: String = requestProperty("publishing.space.user")
|
||||||
val spaceToken: String = requestProperty("publishing.space.token")
|
val spaceToken: String = requestProperty("publishing.space.token")
|
||||||
|
|
||||||
@ -161,11 +165,12 @@ internal fun Project.addSpacePublishing(spaceRepo: String) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
internal fun Project.addSonatypePublishing() {
|
internal fun Project.addSonatypePublishing() {
|
||||||
|
if (requestPropertyOrNull("publishing.sonatype") == "false") return
|
||||||
|
|
||||||
val sonatypeUser: String = requestProperty("publishing.sonatype.user")
|
val sonatypeUser: String = requestProperty("publishing.sonatype.user")
|
||||||
val sonatypePassword: String = requestProperty("publishing.sonatype.password")
|
val sonatypePassword: String = requestProperty("publishing.sonatype.password")
|
||||||
val signingId: String? = requestPropertyOrNull("publishing.signing.id")
|
val signingId: String? = requestPropertyOrNull("publishing.signing.id")
|
||||||
|
|
||||||
|
|
||||||
allprojects {
|
allprojects {
|
||||||
plugins.withId("maven-publish") {
|
plugins.withId("maven-publish") {
|
||||||
configure<PublishingExtension> {
|
configure<PublishingExtension> {
|
||||||
|
Loading…
Reference in New Issue
Block a user