Skip to content

Commit a97b6f3

Browse files
build: add input to release workflow (#653)
1 parent 0207319 commit a97b6f3

File tree

1 file changed

+12
-3
lines changed

1 file changed

+12
-3
lines changed

.github/workflows/release.yml

+12-3
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,13 @@ name: Release
22

33
on:
44
workflow_dispatch:
5+
inputs:
6+
candidate:
7+
type: choice
8+
description: Choose a candidate
9+
options:
10+
- RC
11+
- GA
512

613
env:
714
JAVAFX_VERSION: '21'
@@ -37,14 +44,16 @@ jobs:
3744
id: vars
3845
shell: bash
3946
run: |
40-
mvn -B versions:set -DremoveSnapshot
47+
mvn -B -ntp -q versions:set -DremoveSnapshot -DgenerateBackupPoms=false
4148
PROJECT_VERSION=$(mvn help:evaluate -Dexpression=project.version -q -DforceStdout)
4249
APP_VERSION=$PROJECT_VERSION
4350
S3_PATH=$PROJECT_VERSION
44-
if [[ "$PROJECT_VERSION" == *-RC* ]]; then
45-
APP_VERSION=`echo $PROJECT_VERSION | cut -d- -f1`
51+
CANDIDATE=${{ github.event.inputs.candidate }}
52+
if [[ "$CANDIDATE" == RC ]]; then
53+
PROJECT_VERSION=${PROJECT_VERSION}-RC
4654
S3_PATH=RC/$PROJECT_VERSION
4755
fi
56+
echo "Releasing.. "$PROJECT_VERSION
4857
echo ::set-output name=APP_VERSION::$APP_VERSION
4958
echo ::set-output name=PROJECT_VERSION::$PROJECT_VERSION
5059
echo ::set-output name=S3_PATH::$S3_PATH

0 commit comments

Comments
 (0)