forked from gnieh/logback-journal
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci: add package deployment on release
- Loading branch information
1 parent
4d28811
commit f7c5205
Showing
2 changed files
with
64 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
name: Main Build | ||
|
||
on: | ||
push: | ||
branches: | ||
- release-0.5.0 | ||
release: | ||
types: [created] | ||
|
||
env: | ||
JAVA_VERSION: "8" | ||
MAVEN_PROFILE: "gh-action" | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Set up JDK ${{ env.JAVA_VERSION }} | ||
uses: actions/setup-java@v3 | ||
with: | ||
java-version: ${{ env.JAVA_VERSION }} | ||
distribution: "temurin" | ||
cache: maven | ||
server-id: central # Value of the publishingServerId of central-publishing-maven-plugin plugin of the pom.xml | ||
server-username: MAVEN_USERNAME # Value of the server username in the settings.xml | ||
server-password: MAVEN_CENTRAL_TOKEN # Value of the server password in the settings.xml | ||
gpg-private-key: ${{ secrets.MAVEN_GPG_PRIVATE_KEY }} # Value of armored the private key | ||
gpg-passphrase: MAVEN_GPG_PASSPHRASE | ||
|
||
- name: Publish package to Sonatype Maven Central | ||
run: mvn -B -P ${{ env.MAVEN_PROFILE}} -Dgpg.keyname=${{ secrets.MAVEN_GPG_KEYNAME }} deploy |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters