-
Notifications
You must be signed in to change notification settings - Fork 2
43 lines (41 loc) · 1.45 KB
/
release.yaml
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
39
40
41
42
43
name: Component Checker Release
on:
pull_request:
types: [closed]
paths:
- '.github/project.yml'
jobs:
release:
runs-on: ubuntu-latest
permissions:
contents: write
name: release
if: ${{github.event.pull_request.merged == true}}
steps:
- uses: radcortez/project-metadata-action@main
name: retrieve project metadata
id: metadata
with:
github-token: ${{secrets.GITHUB_TOKEN}}
metadata-file-path: '.github/project.yml'
- uses: actions/checkout@v2
- uses: actions/setup-java@v1
with:
java-version: 11
- name: maven release ${{steps.metadata.outputs.current-version}}
run: |
java -version
git config --global user.name "Component Checker CI"
git config --global user.email "[email protected]"
git checkout -b release
mvn -B release:prepare -DreleaseVersion=${{steps.metadata.outputs.current-version}} -DdevelopmentVersion=${{steps.metadata.outputs.next-version}} -Pjboss-release
git checkout ${{github.base_ref}}
git rebase release
#mvn -B release:perform -Pjboss-release
git push
git push --tags
- name: Create GH release
uses: softprops/action-gh-release@v2
with:
files: target/component-mapper-${{steps.metadata.outputs.current-version}}-shaded.jar
tag_name: ${{steps.metadata.outputs.current-version}}