-
Notifications
You must be signed in to change notification settings - Fork 2
36 lines (32 loc) · 1.1 KB
/
prepare_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
name: Prepare dina-base-api release
on: workflow_dispatch
permissions:
contents: write
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
ref: dev
persist-credentials: false
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: '17'
- name: Set Version
run: |
mvn build-helper:parse-version versions:set -DnewVersion=\${parsedVersion.majorVersion}.\${parsedVersion.minorVersion} versions:commit
mvn help:evaluate -Dexpression=project.version -q -DforceStdout > version.txt
- name: Push to dev
env:
GITHUB_TOKEN: ${{ secrets.BICE_PAT }}
run: |
VERSION=$(cat version.txt)
rm version.txt
git config user.name github-actions
git config user.email "[email protected]"
git add .
git commit -m "Prepare $VERSION release"
git push https://AAFC-BICE:${GITHUB_TOKEN}@github.com/AAFC-BICoE/dina-base-api.git dev