-
Notifications
You must be signed in to change notification settings - Fork 0
38 lines (36 loc) · 1.21 KB
/
maven-release.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
name: maven-release
on:
workflow_dispatch:
inputs:
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:
release:
runs-on: ubuntu-latest
steps:
# Checkout source code, set up Java, etc. Then...
- name: Checkout code
uses: actions/checkout@v4
- name: Set up JDK 17
uses: actions/setup-java@v4
with:
java-version: "17"
distribution: "temurin"
cache: "maven"
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: "20"
- name: Maven Release
run: |
git config --global user.email "[email protected]"
git config --global user.name "GitHub Actions"
mvn release:prepare -B -Dpassword=${GITLAB_ACCESS_TOKEN_PW} -DreleaseVersion=${{ github.event.inputs.releaseVersion }} -DdevelopmentVersion=${{ github.event.inputs.developmentVersion }}
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}