0.1.1-beta1 #5
Workflow file for this run
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
name: Release | |
on: | |
release: | |
types: [published] | |
workflow_dispatch: | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: get version from tag | |
id: get_version | |
run: | | |
realversion="${GITHUB_REF/refs\/tags\//}" | |
realversion="${realversion//v/}" | |
echo "VERSION=$realversion" >> $GITHUB_OUTPUT | |
- name: Set up publishing to maven central | |
uses: actions/setup-java@v2 | |
with: | |
java-version: '8' | |
distribution: 'temurin' | |
server-id: ossrh | |
server-username: MAVEN_USERNAME | |
server-password: MAVEN_PASSWORD | |
- name: Install gpg key | |
run: | | |
cat <(echo -e "${{ secrets.OSSH_GPG_SECRET_KEY }}") | gpg --batch --import | |
gpg --list-secret-keys --keyid-format LONG | |
- name: mvn versions - Core | |
run: mvn versions:set -DnewVersion=${{ steps.get_version.outputs.VERSION }} | |
working-directory: ./core | |
- name: Publish - Core | |
run: | | |
mvn --no-transfer-progress \ | |
--batch-mode \ | |
-Dgpg.passphrase='${{ secrets.OSSH_GPG_SECRET_KEY_PASSWORD }}' \ | |
-DskipTests deploy -P release | |
env: | |
MAVEN_USERNAME: ${{secrets.OSSH_USERNAME}} | |
MAVEN_PASSWORD: ${{secrets.OSSH_TOKEN}} | |
working-directory: ./core | |
continue-on-error: true # This step will not stop the job even if it fails | |
- name: mvn versions - EntraID | |
run: mvn versions:set -DnewVersion=${{ steps.get_version.outputs.VERSION }} | |
working-directory: ./entraid | |
- name: set release versions | |
run: mvn versions:use-releases -DallowSnapshots=false -DgenerateBackupPoms=false | |
working-directory: ./entraid | |
- name: Publish - EntraID | |
run: | | |
mvn --no-transfer-progress \ | |
--batch-mode \ | |
-Dgpg.passphrase='${{ secrets.OSSH_GPG_SECRET_KEY_PASSWORD }}' \ | |
-DskipTests -Dmaven.test.skip=true deploy -P release | |
env: | |
MAVEN_USERNAME: ${{secrets.OSSH_USERNAME}} | |
MAVEN_PASSWORD: ${{secrets.OSSH_TOKEN}} | |
working-directory: ./entraid |