This repository has been archived by the owner on Nov 12, 2021. It is now read-only.
generated from wuespace/telestion-extension-template
-
Notifications
You must be signed in to change notification settings - Fork 0
95 lines (82 loc) · 2.61 KB
/
ci.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
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
# For most projects, this workflow file will not need changing; you simply need
# to commit it to your repository.
#
# ******** NOTE ********
# If you need access to the GitHub Maven package registry from other repositories,
# create a personal access token with the following scopes:
# - read:packages
# and name it "READ_PACKAGES".
# After this step, overwrite the default GITHUB_TOKEN environment variable with the created PAT
# in the gradle build and test steps.
name: CI
# Events that trigger this workflow
on: [push, pull_request]
jobs:
build:
name: Build packages
runs-on: ubuntu-latest
steps:
- name: Checkout 📥
uses: actions/[email protected]
with:
submodules: true
- name: Restore gradle cache ♻️
uses: actions/[email protected]
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: |
${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }}
restore-keys: |
${{ runner.os }}-gradle-
- name: Set up JDK 16 💿
uses: actions/[email protected]
with:
distribution: 'zulu'
java-version: '16'
java-package: jdk
# - name: Set up Python 3.8 💿
# uses: actions/[email protected]
# with:
# python-version: 3.8
- name: Build packages 🛠️
run: chmod +x gradlew && ./gradlew build
env:
GITHUB_TOKEN: ${{ secrets.READ_PACKAGES }}
test:
name: Test packages
runs-on: ubuntu-latest
steps:
- name: Checkout 📥
uses: actions/[email protected]
with:
submodules: true
- name: Restore gradle cache ♻️
uses: actions/[email protected]
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: |
${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }}
restore-keys: |
${{ runner.os }}-gradle-
- name: Set up JDK 16 💿
uses: actions/[email protected]
with:
distribution: 'zulu'
java-version: '16'
java-package: jdk
# - name: Set up Python 3.8 💿
# uses: actions/[email protected]
# with:
# python-version: 3.8
- name: Build packages 🛠️
run: chmod +x gradlew && ./gradlew build
env:
GITHUB_TOKEN: ${{ secrets.READ_PACKAGES }}
- name: Test packages 🛃
run: ./gradlew test
env:
GITHUB_TOKEN: ${{ secrets.READ_PACKAGES }}