From 206ea8ac5a76b2ba4a636b218d7b88b91e200d69 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=87=95=E9=99=87=E7=90=AA?= Date: Wed, 2 Apr 2025 18:35:52 +0800 Subject: [PATCH] =?UTF-8?q?feat(=E6=B5=81=E6=B0=B4=E7=BA=BF):=20github?= =?UTF-8?q?=E7=9A=84=E6=B5=81=E6=B0=B4=E7=BA=BF=E9=85=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/release.yml | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 966850c..189af68 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -10,27 +10,24 @@ jobs: steps: - name: Checkout Git Repo uses: actions/checkout@v2 + - name: Set up Maven Central Repo uses: actions/setup-java@v1 with: java-version: 1.8 - server-id: sonatype-nexus-staging + server-id: central server-username: ${{ secrets.OSSRH_USER }} server-password: ${{ secrets.OSSRH_PASSWORD }} gpg-passphrase: ${{ secrets.GPG_PASSWORD }} - name: Configure GPG for CI run: | - # Create .gnupg directory mkdir -p ~/.gnupg/ - # Configure GPG to use non-interactive mode echo "use-agent" > ~/.gnupg/gpg.conf echo "pinentry-mode loopback" >> ~/.gnupg/gpg.conf echo "allow-loopback-pinentry" > ~/.gnupg/gpg-agent.conf - # Set permissions chmod 700 ~/.gnupg chmod 600 ~/.gnupg/* - # Restart agent gpg-connect-agent reloadagent /bye - name: Publish to Maven Central Repo @@ -39,4 +36,5 @@ jobs: gpg_private_key: ${{ secrets.GPG_SECRET }} gpg_passphrase: ${{ secrets.GPG_PASSWORD }} nexus_username: ${{ secrets.OSSRH_USER }} - nexus_password: ${{ secrets.OSSRH_PASSWORD }} \ No newline at end of file + nexus_password: ${{ secrets.OSSRH_PASSWORD }} + maven_args: "-Dmaven.deploy.skip=false -DaltDeploymentRepository=central::default::https://central.sonatype.com/service/local/staging/deploy/maven2/"