-
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Move from Jitpack to BlueColored Repo
- Loading branch information
1 parent
3832fd4
commit 8606dfb
Showing
4 changed files
with
114 additions
and
8 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,43 @@ | ||
name: Deploy to BlueColored Repo | ||
|
||
on: | ||
release: | ||
types: [ released ] | ||
|
||
# Allows you to run this workflow manually from the Actions tab | ||
workflow_dispatch: | ||
inputs: | ||
TAG_NAME: | ||
description: 'GitHub Tag Name (for comparing with project version)' | ||
required: true | ||
|
||
env: | ||
TAG_NAME: ${{ github.event.inputs.TAG_NAME || github.event.release.tag_name }} | ||
|
||
jobs: | ||
deploy: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Set up JDK 17 | ||
uses: actions/setup-java@v4 | ||
with: | ||
java-version: '17' | ||
distribution: 'temurin' | ||
- name: Check tag with project version | ||
run: | | ||
PROJECT_VERSION=$(mvn help:evaluate -Dexpression=project.version -q -DforceStdout) | ||
# Remove 'v' prefix from tag name | ||
TAG_VERSION=$(sed 's/^v//g' <<< "$TAG_NAME") | ||
if [ "$PROJECT_VERSION" != "$TAG_VERSION" ]; then | ||
echo "Project version ($PROJECT_VERSION) does not match tag ($TAG_VERSION)" | ||
exit 1 | ||
fi | ||
- name: Set up credentials | ||
shell: bash | ||
env: | ||
PASSWORD: ${{ secrets.MAVEN_SECRET }} | ||
run: echo "<settings><servers><server><id>bluecolored-releases</id><username>technicjelle</username><password>$PASSWORD</password></server></servers></settings>" > ~/.m2/settings.xml | ||
- name: Deploy | ||
run: mvn clean deploy |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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
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