File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ # This workflow will build a package using Maven and then publish it to GitHub packages when a release is created
2+ # For more information see: https://github.com/actions/setup-java#apache-maven-with-a-settings-path
3+
4+ name : Publish package to the Maven Central Repository
5+ on :
6+ release :
7+ types : [created]
8+ jobs :
9+ publish :
10+ runs-on : ubuntu-latest
11+ steps :
12+ - uses : actions/checkout@v2
13+ - name : Set up Maven Central Repository
14+ uses : actions/setup-java@v1
15+ with :
16+ java-version : 14
17+ server-id : ossrh
18+ server-username : MAVEN_USERNAME
19+ server-password : MAVEN_PASSWORD
20+ gpg-private-key : ${{ secrets.MAVEN_GPG_PRIVATE_KEY }}
21+ gpg-passphrase : MAVEN_GPG_PASSPHRASE
22+ - name : Publish package
23+ run : mvn -B deploy
24+ env :
25+ MAVEN_USERNAME : ${{ secrets.OSSRH_USERNAME }}
26+ MAVEN_PASSWORD : ${{ secrets.OSSRH_PASSWORD }}
27+ MAVEN_GPG_PASSPHRASE : ${{ secrets.MAVEN_GPG_PASSPHRASE }}
You can’t perform that action at this time.
0 commit comments