HIV_SCREENING Release #1
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: HIV_SCREENING Release | |
on: | |
workflow_dispatch: | |
inputs: | |
branch: | |
description: "The branch to checkout when cutting the release." | |
required: true | |
default: "main" | |
releaseVersion: | |
description: "Default version to use when preparing a release." | |
required: true | |
default: "X.Y.Z" | |
developmentVersion: | |
description: "Default version to use for new local working copy." | |
required: true | |
default: "X.Y.Z-SNAPSHOT" | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout Source Code | |
uses: actions/checkout@v2 | |
with: | |
ref: ${{ github.event.inputs.branch }} | |
- name: Set up JDK 8 | |
uses: actions/setup-java@v2 | |
with: | |
distribution: 'temurin' | |
java-version: '8' | |
- name: Build and Test | |
run: mvn --batch-mode --update-snapshots clean package | |
- name: Configure Git User | |
run: | | |
git config user.email "actions@github.com" | |
git config user.name "GitHub Actions" | |
- name: Perform Release | |
run: mvn release:prepare release:perform -B -s .maven-settings.xml -DreleaseVersion=${{ github.event.inputs.releaseVersion }} -DdevelopmentVersion=${{ github.event.inputs.developmentVersion }} | |
env: | |
MAVEN_REPO_USERNAME: ${{ secrets.MAVEN_REPO_USERNAME }} | |
MAVEN_REPO_PASSWORD: ${{ secrets.MAVEN_REPO_PASSWORD }} | |
GITHUB_ACTOR: ${{ github.actor }} | |
GITHUB_TOKEN: ${{ github.token }} |