-
Notifications
You must be signed in to change notification settings - Fork 0
101 lines (101 loc) · 3.24 KB
/
release.yml
File metadata and controls
101 lines (101 loc) · 3.24 KB
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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
name: Release CI
on:
push:
tags:
- 'v*'
env:
CI: true
GITHUB_BRANCH: ${{ github.ref }}
GITHUB_HEAD_REF: ${{ github.head_ref }}
GITHUB_BASE_REF: ${{ github.base_ref }}
GITHUB_COMMIT: ${{ github.sha }}
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ ubuntu-latest, macOS-latest, windows-latest ]
java: [ '17.0.1' ]
fail-fast: false
name: ${{ matrix.os }} JDK ${{ matrix.java }}
steps:
- name: Git checkout
uses: actions/checkout@v2
- name: Set up JDK
uses: actions/setup-java@v1
with:
java-version: ${{ matrix.java }}
- name: Echo JAVA_HOME
run: echo $JAVA_HOME
- name: Cache Gradle packages
uses: actions/cache@v1
with:
path: ~/.gradle/caches
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle') }}
restore-keys: ${{ runner.os }}-gradle
- name: Verify Gradle Wrapper
uses: gradle/wrapper-validation-action@v1
- name: Execute clean
run: ./gradlew --info --stacktrace clean
- name: Execute check
run: ./gradlew --info --stacktrace check
- name: Execute build
run: ./gradlew --info --stacktrace build
- name: Execute jlinkZip
run: ./gradlew --info --stacktrace jlinkZip
- name: Execute jpackage
run: ./gradlew --info --stacktrace jpackage
- name: Upload DMG Release Asset
if: matrix.os == 'macOS-latest'
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: build/jpackage/*.dmg
tag: ${{ github.ref }}
overwrite: true
file_glob: true
- name: Upload EXE Release Asset
if: matrix.os == 'windows-latest'
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: build/jpackage/*.exe
tag: ${{ github.ref }}
overwrite: true
file_glob: true
- name: Upload MSI Release Asset
if: matrix.os == 'windows-latest'
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: build/jpackage/*.msi
tag: ${{ github.ref }}
overwrite: true
file_glob: true
- name: Upload DEB Release Asset
if: matrix.os == 'ubuntu-latest'
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: build/jpackage/*.deb
tag: ${{ github.ref }}
overwrite: true
file_glob: true
- name: Upload RPM Release Asset
if: matrix.os == 'ubuntu-latest'
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: build/jpackage/*.rpm
tag: ${{ github.ref }}
overwrite: true
file_glob: true
- name: Upload ZIP Release Asset
if: matrix.os == 'ubuntu-latest'
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: build/distributions/*.zip
tag: ${{ github.ref }}
overwrite: true
file_glob: true