Skip to content

Commit

Permalink
Tries extending gpg key
Browse files Browse the repository at this point in the history
  • Loading branch information
ryankazokas committed Oct 18, 2024
1 parent d73fa68 commit 18c9b02
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions .github/workflows/maven.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ on:
push:
branches:
- 'master'
- 'hotfix/**'

jobs:
build:
Expand Down Expand Up @@ -36,6 +37,16 @@ jobs:
server-password: MAVEN_PASSWORD
gpg-private-key: ${{ secrets.GPG_SECRET_KEY }}
gpg-passphrase: MAVEN_GPG_PASSPHRASE
- name: list-keys
run: |
gpg --list-keys --keyid-format LONG
- name: Get GPG Key ID
id: gpg-key-id
run: |
gpg --list-secret-keys --keyid-format LONG | grep '^sec' | awk '{print $2}' | cut -d'/' -f2
- name: Extend GPG key expiration
run: |
echo -e "expire\n1y\nsave" | gpg --batch --command-fd 0 --edit-key ${{ steps.gpg-key-id.outputs.key-id }}
- name: Publish package to maven central
run: mvn --batch-mode clean deploy -P central-deploy -DskipTests=true --update-snapshots -Prelease
env:
Expand Down

0 comments on commit 18c9b02

Please sign in to comment.