Skip to content

Commit 234aa46

Browse files
committed
Reuse bundled dist script at run_self job
1 parent 5bfe54c commit 234aa46

File tree

1 file changed

+16
-3
lines changed

1 file changed

+16
-3
lines changed

.github/workflows/ci.yml

+16-3
Original file line numberDiff line numberDiff line change
@@ -34,13 +34,25 @@ jobs:
3434
git diff
3535
exit 1
3636
fi
37+
# post processes
38+
- name: Upload dist for post job
39+
if: ${{ always() }}
40+
uses: actions/upload-artifact@v3
41+
with:
42+
name: js_dist
43+
path: |
44+
dist/
45+
action.yml
3746
- name: Create dist/*.js size json
47+
if: ${{ always() }}
3848
run: |
3949
inner=$(find ./dist -type f -printf '%s %f\n' | jq -s -R 'split("\n") | map(select(. != "")) | map(split(" ")) | map({"value": .[0]|tonumber, "key": .[1], "name": .[1], "unit": "byte"})')
4050
jq -n --arg key "dist_size" --arg name "dist_size" --argjson metrics "$inner" '$ARGS.named' > dist_js_sizes.json
4151
- name: Create dummy coverage
52+
if: ${{ always() }}
4253
run: touch coverage.out
4354
- uses: k1LoW/octocov-action@v0
55+
if: ${{ always() }}
4456
env:
4557
OCTOCOV_CUSTOM_METRICS_DIST_JS: dist_js_sizes.json
4658
test:
@@ -56,8 +68,9 @@ jobs:
5668
if: ${{ always() }}
5769
needs: [ check, check-dist, test ]
5870
steps:
59-
- uses: actions/checkout@v4
60-
- uses: ./.github/actions/setup-deno-with-cache
61-
- run: deno task bundle
71+
- name: Download bundled dist
72+
uses: actions/download-artifact@v3
73+
with:
74+
name: js_dist
6275
- name: Run self action
6376
uses: ./

0 commit comments

Comments
 (0)