From e2d23d6f6295611c42a1352fe75107ca0d28aea4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=87=B4=E8=8A=82?= Date: Tue, 21 Feb 2023 16:21:53 +0800 Subject: [PATCH] add snapshot yaml --- .github/workflows/snapshot.yml | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 .github/workflows/snapshot.yml diff --git a/.github/workflows/snapshot.yml b/.github/workflows/snapshot.yml new file mode 100644 index 000000000..b648734fc --- /dev/null +++ b/.github/workflows/snapshot.yml @@ -0,0 +1,31 @@ +# This workflow will build and release a Java project with Maven, and cache/restore any dependencies to improve the workflow execution time +# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven + +name: Snapshot + +on: + workflow_dispatch: + + +jobs: + release: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - name: Set up JDK 17 + uses: actions/setup-java@v3 + with: + java-version: '17' + distribution: 'temurin' + cache: maven + server-id: ossrh + server-username: MAVEN_USERNAME + server-password: MAVEN_PASSWORD + gpg-private-key: ${{ secrets.MAVEN_GPG_PRIVATE_KEY }} # Value of the GPG private key to import + gpg-passphrase: MAVEN_GPG_PASSPHRASE # env variable for GPG private key passphrase + - name: Build with Maven + run: mvn --batch-mode deploy -DskipTests -Psnapshot + env: + MAVEN_USERNAME: ${{ secrets.MAVEN_USERNAME }} + MAVEN_PASSWORD: ${{ secrets.MAVEN_PASSWORD }} + MAVEN_GPG_PASSPHRASE: ${{ secrets.MAVEN_GPG_PASSPHRASE }}