-
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.
- Loading branch information
1 parent
6ff87c9
commit 8351111
Showing
1 changed file
with
38 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,38 @@ | ||
name: Artifactory Milestone Release | ||
|
||
on: | ||
workflow_dispatch: | ||
inputs: | ||
releaseVersion: | ||
description: "Milestone release version" | ||
required: true | ||
|
||
jobs: | ||
build: | ||
name: Release milestone to Artifactory | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout source code | ||
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 | ||
|
||
- name: Set up JDK 17 | ||
uses: actions/setup-java@0ab4596768b603586c0de567f2430c30f5b0d2b0 #v3.13.0 | ||
with: | ||
java-version: '17' | ||
distribution: 'temurin' | ||
cache: 'maven' | ||
|
||
- name: Capture release version | ||
run: echo RELEASE_VERSION=${{ github.event.inputs.releaseVersion }} >> $GITHUB_ENV | ||
|
||
- name: Update release version | ||
run: mvn versions:set -DgenerateBackupPoms=false -DnewVersion=$RELEASE_VERSION | ||
|
||
- name: Enforce release rules | ||
run: mvn org.apache.maven.plugins:maven-enforcer-plugin:enforce -Drules=requireReleaseDeps | ||
|
||
- name: Build with Maven and deploy to Artifactory's milestone repository | ||
env: | ||
ARTIFACTORY_USERNAME: ${{ secrets.ARTIFACTORY_USERNAME }} | ||
ARTIFACTORY_PASSWORD: ${{ secrets.ARTIFACTORY_PASSWORD }} | ||
run: mvn -P artifactory-milestone -s settings.xml --batch-mode -Dmaven.test.skip=true deploy |