-
Notifications
You must be signed in to change notification settings - Fork 56
40 lines (39 loc) · 1.28 KB
/
bundle-report.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
name: Bundle size report
on:
pull_request:
push:
branches:
- main
jobs:
bundle-report:
runs-on: ubuntu-latest
permissions:
deployments: write
id-token: write
steps:
- uses: actions/checkout@v2
- name: Reconfigure git to use HTTP authentication
run: >
git config --global url."https://github.com/".insteadOf
ssh://[email protected]/
- name: Use Node.js 20.x
uses: actions/setup-node@v1
with:
node-version: 20.x
- run: npm ci
- name: Build bundle reports
run: |
mkdir bundle-reports
npm run sourcemap -- --html bundle-reports/index.html
- uses: aws-actions/configure-aws-credentials@v1
with:
aws-region: eu-west-2
role-to-assume: arn:aws:iam::${{ secrets.ABLY_AWS_ACCOUNT_ID_SDK }}:role/ably-sdk-builds-ably-js
role-session-name: "${{ github.run_id }}-${{ github.run_number }}"
- uses: ably/sdk-upload-action@v1
with:
sourcePath: bundle-reports
githubToken: ${{ secrets.GITHUB_TOKEN }}
artifactName: bundle-report
# This step performs some validation and may fail, so it should come after the steps that we want to always execute.
- run: npm run modulereport