Skip to content

Commit 66d6f1d

Browse files
committed
build: let publish plugin manage signature
1 parent db8faca commit 66d6f1d

2 files changed

Lines changed: 5 additions & 10 deletions

File tree

.github/workflows/publish.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,14 +24,15 @@ jobs:
2424

2525
- name: list gpg keys
2626
shell: bash
27-
run: gpg -K --keyid-format=long
27+
run: |
28+
gpg -K --keyid-format=long
2829
2930
- name: import GPG private key
3031
shell: bash
3132
run: |
3233
echo "use-agent" >> ~/.gnupg/gpg.conf
3334
echo "pinentry-mode loopback" >> ~/.gnupg/gpg.conf
34-
echo -e "${{ secrets.GPG_PRIVATE_KEY }}" | gpg --import --batch
35+
echo -e "${{ secrets.ORG_GPG_PRIVATE_KEY }}" | gpg --import --batch
3536
for fpr in $(gpg --list-keys --with-colons | awk -F: '/fpr:/ {print $10}' | sort -u);
3637
do
3738
echo -e "5\\ny\\n" | gpg --batch --command-fd 0 --expert --edit-key $fpr trust;
@@ -44,4 +45,4 @@ jobs:
4445
ORG_GRADLE_PROJECT_mavenCentralPassword: ${{ secrets.CENTRAL_SONATYPE_TOKEN_PASSWORD }}
4546
ORG_GRADLE_PROJECT_signingInMemoryKey: ${{ secrets.GPG_PRIVATE_KEY }}
4647
ORG_GRADLE_PROJECT_signingInMemoryKeyPassword: ${{ secrets.GPG_PASSPHRASE }}
47-
run: ./gradlew publishToMavenCentral -Psigning.gnupg.executable=gpg -Psigning.gnupg.passphrase="${{ secrets.GPG_PASSPHRASE }}"
48+
run: ./gradlew publishToMavenCentral --stacktrace

build.gradle.kts

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
11
plugins {
22
java
33
`java-library`
4-
signing
54
`maven-publish`
6-
id("com.vanniktech.maven.publish") version "0.34.0"
5+
id("com.vanniktech.maven.publish") version "0.35.0"
76
}
87

98
group = "org.eclipse.dataplane"
@@ -37,11 +36,6 @@ tasks.test {
3736
useJUnitPlatform()
3837
}
3938

40-
signing {
41-
useGpgCmd()
42-
sign(publishing.publications)
43-
}
44-
4539
mavenPublishing {
4640
publishToMavenCentral(true)
4741

0 commit comments

Comments
 (0)