-
Notifications
You must be signed in to change notification settings - Fork 1
76 lines (65 loc) · 1.65 KB
/
github_actions.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
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
name: TileDB-Cloud-JDBC
on:
workflow_dispatch:
push:
tags:
- '*'
branches:
- 'main'
pull_request:
jobs:
Test:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ ubuntu-22.04, macos-12, windows-2019 ]
steps:
- name: checkout
uses: actions/checkout@v4
- name: Set up Java
uses: actions/setup-java@v4
with:
distribution: 'adopt'
java-version: '11'
check-latest: true
- run: |
./gradlew checkFormat
shell: bash
name: checkFormat
- run: |
./gradlew assemble
shell: bash
name: assemble
- name: test
env:
API_TOKEN: ${{ secrets.API_TOKEN }}
run: |
./gradlew test
shell: bash
Release:
if: startsWith(github.ref, 'refs/tags/')
needs: [Test]
name: Create-Release
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Java
uses: actions/setup-java@v4
with:
distribution: 'adopt'
java-version: '11'
check-latest: false
- name: Create-Jars
run: unset SYSTEM; set +e; ./gradlew assemble; ./gradlew shadowJar; mkdir jars/; cp ./build/libs/*.jar jars/
- name: Create-Release
id: create_release
uses: softprops/action-gh-release@v2
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
files: jars/*.jar
tag_name: ${{ github.event.release.tag_name }}
name: ${{ github.event.release.tag_name }}
draft: false
prerelease: false