-
-
Notifications
You must be signed in to change notification settings - Fork 109
39 lines (35 loc) · 1.11 KB
/
compressed-size.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
name: compressed-size
on:
pull_request:
branches:
- main
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: dorny/paths-filter@v2
id: filter
with:
filters: |
wmr:
- 'packages/wmr/**'
- 'examples/demo/**'
preact-iso:
- 'packages/preact-iso/**'
- name: compressed-size-action
if: ${{ steps.filter.outputs.wmr == 'true' }}
uses: preactjs/compressed-size-action@v2
with:
pattern: '{packages/wmr/wmr.cjs,examples/demo/dist/**/*.{js,css,html}}'
build-script: ci
strip-hash: "\\.(\\w{8})\\.(?:js|css)$"
repo-token: '${{ secrets.GITHUB_TOKEN }}'
- name: compressed-size-action
if: ${{ steps.filter.outputs.preact-iso == 'true' }}
uses: preactjs/compressed-size-action@v2
with:
pattern: '{packages/preact-iso/*.js,packages/preact-iso/.dist/*.js}'
build-script: 'iso test-build'
strip-hash: "\\.(\\w{8})\\.js$"
repo-token: '${{ secrets.GITHUB_TOKEN }}'