-
Notifications
You must be signed in to change notification settings - Fork 4.2k
41 lines (37 loc) · 1.26 KB
/
process-character-sheet.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
name: Processes changed character-sheets and updates CDN bucket and/or sheet-http database as needed
on:
push:
branches: ["team/csc"]
jobs:
changes:
runs-on: ubuntu-latest
# Set job outputs to values from filter step
outputs:
sheet: ${{ steps.filter.outputs.sheet }}
steps:
- uses: actions/checkout@v3
- uses: dorny/paths-filter@v2
id: filter
with:
# Enable listing of files matching each filter.
# Paths to files will be available in `${FILTER_NAME}_files` output variable.
# Paths will be escaped and space-delimited.
# Output is usable as command-line argument list in Linux shell
list-files: shell
filters: |
sheet:
- '*/sheet.json'
process-character-sheets:
name: Process character-sheet HTML/CSS
needs: changes
if: ${{ needs.changes.outputs.sheet == 'true'}}
runs-on: ubuntu-latest
env:
NPM_TOKEN: ${{ secrets.REPO_ACCESS_TOKEN }}
steps:
- uses: actions/checkout@v3
- uses: oven-sh/setup-bun@v1
# run any `bun` or `bunx` command
- run: bun install
working-directory: contrib/sheet-pixie
- run: bun run contrib/sheet-pixie/index.ts ${{ steps.filter.outputs.sheet_files }}