This is an automated email from the ASF dual-hosted git repository. vladimirsitnikov pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/calcite-avatica.git
commit 0e735a8dc2133f6aa07fb0deed978e3fcf225d9a Author: Vladimir Sitnikov <[email protected]> AuthorDate: Sun Dec 22 16:10:46 2019 +0300 Move PGP signing to com.github.vlsi.stage-vote-release Gradle plugin --- build.gradle.kts | 45 +-------------------------------------------- gradle.properties | 2 +- release/build.gradle.kts | 3 +-- 3 files changed, 3 insertions(+), 47 deletions(-) diff --git a/build.gradle.kts b/build.gradle.kts index e1870e5..1730090 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -61,14 +61,10 @@ val enableSpotBugs = props.bool("spotbugs", default = false) val skipCheckstyle by props() val skipSpotless by props() val skipJavadoc by props() -val skipSigning by props(props.bool("skipSign")) +// Inherited from stage-vote-release-plugin: skipSign, useGpgCmd val enableMavenLocal by props() val enableGradleMetadata by props() -// By default use Java implementation to sign artifacts -// When useGpgCmd=true, then gpg command line tool is used for signing -val useGpgCmd by props() - ide { copyrightToAsf() ideaInstructionsUri = @@ -133,12 +129,6 @@ releaseParams { }) } } - validateBeforeBuildingReleaseArtifacts += Runnable { - if (useGpgCmd && findProperty("signing.gnupg.keyName") == null) { - throw GradleException("Please specify signing key id via signing.gnupg.keyName " + - "(see https://github.com/gradle/gradle/issues/8657)") - } - } } val javadocAggregate by tasks.registering(Javadoc::class) { @@ -229,20 +219,6 @@ allprojects { fileMode = "664".toInt(8) } - plugins.withType<SigningPlugin> { - afterEvaluate { - configure<SigningExtension> { - val release = rootProject.releaseParams.release.get() - // Note it would still try to sign the artifacts, - // however it would fail only when signing a RELEASE version fails - isRequired = release - if (useGpgCmd) { - useGpgCmd() - } - } - } - } - tasks { withType<Javadoc>().configureEach { (options as StandardJavadocDocletOptions).apply { @@ -271,17 +247,6 @@ allprojects { } } - if (!isReleaseVersion || skipSigning) { - plugins.withType<SigningPlugin> { - afterEvaluate { - configure<SigningExtension> { - // It would still try to sign the artifacts, - // but it would refrain from failing the build - isRequired = false - } - } - } - } plugins.withType<JavaPlugin> { configure<JavaPluginConvention> { sourceCompatibility = JavaVersion.VERSION_1_8 @@ -296,7 +261,6 @@ allprojects { } val sourceSets: SourceSetContainer by project - apply(plugin = "signing") apply(plugin = "de.thetaphi.forbiddenapis") apply(plugin = "maven-publish") @@ -306,13 +270,6 @@ allprojects { } } - if (isReleaseVersion && !skipSigning) { - configure<SigningExtension> { - // Sign all the publications - sign(publishing.publications) - } - } - if (!skipSpotless) { spotless { java { diff --git a/gradle.properties b/gradle.properties index 0e3d45e..0eeb912 100644 --- a/gradle.properties +++ b/gradle.properties @@ -35,7 +35,7 @@ calcite.avatica.version=1.16.0 com.diffplug.gradle.spotless.version=3.25.0 com.github.johnrengelman.shadow.version=5.1.0 com.github.spotbugs.version=2.0.0 -com.github.vlsi.vlsi-release-plugins.version=1.50 +com.github.vlsi.vlsi-release-plugins.version=1.52 com.google.protobuf.version=0.8.10 de.thetaphi.forbiddenapis.version=2.7 org.jetbrains.gradle.plugin.idea-ext.version=0.5 diff --git a/release/build.gradle.kts b/release/build.gradle.kts index 6ca930e..afded3d 100644 --- a/release/build.gradle.kts +++ b/release/build.gradle.kts @@ -28,7 +28,6 @@ import com.github.vlsi.gradle.release.dsl.dependencyLicenses import com.github.vlsi.gradle.release.dsl.licensesCopySpec plugins { - signing id("com.github.vlsi.stage-vote-release") } @@ -79,7 +78,7 @@ https://people.apache.org/keys/committer/$committerId.asc https://www.apache.org/dist/$tlpUrl/KEYS N.B. -To create the jars and test $componentName: "./gradlew build -Prelease -PskipSigning". +To create the jars and test $componentName: "./gradlew build -Prelease -PskipSign". If you do not have a Java environment available, you can run the tests using docker. To do so, install docker and docker-compose, then run
