-
Notifications
You must be signed in to change notification settings - Fork 215
36 lines (34 loc) · 1.01 KB
/
main.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: CI
on: [push, pull_request]
jobs:
ci:
name: ${{ matrix.node_version }}
if: ${{ github.actor != 'RWT-bot' }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
node_version: [18, 20]
steps:
- uses: actions/checkout@v4
env:
TOKEN: "${{ github.event_name == 'push' && endsWith(github.ref, 'develop') && matrix.node_version == 20 && secrets.RWT_BOT_PAT || github.token }}"
with:
token: ${{ env.TOKEN }}
- uses: actions/setup-node@v4
with:
cache: npm
node-version: ${{ matrix.node_version }}
- name: Install grunt-cli
run: npm install -g grunt-cli
- name: Install
run: npm install
- name: Build
run: npm run build
- name: Test
run: npm test
- uses: stefanzweifel/git-auto-commit-action@v5
if: ${{ github.event_name == 'push' && endsWith(github.ref, 'develop') && matrix.node_version == 20 }}
with:
commit_message: Update Build
file_pattern: 'build/*.js'