|
97 | 97 | pr_number: ${{ github.event.number }} |
98 | 98 | comment: ${{ steps.asset-size-report.outputs.results }} |
99 | 99 | comment_tag: <!-- browser_agent asset size report --> |
100 | | - - name: Get local stats |
101 | | - id: get-stats |
102 | | - run: | |
103 | | - rum=$(cat ../../build/nr-rum-standard.stats.json); ; echo "rum=$rum" >> $GITHUB_OUTPUT; |
104 | | - full=$(cat ../../build/nr-full-standard.stats.json); ; echo "full=$full" >> $GITHUB_OUTPUT; |
105 | | - spa=$(cat ../../build/nr-spa-standard.stats.json); ; echo "spa=$spa" >> $GITHUB_OUTPUT; |
106 | | - - name: Report rum size to NR |
107 | | - uses: metal-messiah/webpack-build-size-action |
108 | | - with: |
109 | | - nr-api-key: ${{ secrets.INTERNAL_STAGING_INGEST_LICENSE_KEY }} |
110 | | - nr-account-id: '550352' |
111 | | - nr-env: 'staging' |
112 | | - analysis-type: 'webpack' |
113 | | - analysis-file-contents: ${{ steps.get-stats.outputs.rum }} |
114 | | - file-name-filter: '.min.js' |
115 | | - traverse: false |
116 | | - - name: Report full size to NR |
117 | | - uses: metal-messiah/webpack-build-size-action |
118 | | - with: |
119 | | - nr-api-key: ${{ secrets.INTERNAL_STAGING_INGEST_LICENSE_KEY }} |
120 | | - nr-account-id: '550352' |
121 | | - nr-env: 'staging' |
122 | | - analysis-type: 'webpack' |
123 | | - analysis-file-contents: ${{ steps.get-stats.outputs.full }} |
124 | | - file-name-filter: '.min.js' |
125 | | - traverse: false |
126 | | - - name: Report spa size to NR |
127 | | - uses: metal-messiah/webpack-build-size-action |
128 | | - with: |
129 | | - nr-api-key: ${{ secrets.INTERNAL_STAGING_INGEST_LICENSE_KEY }} |
130 | | - nr-account-id: '550352' |
131 | | - nr-env: 'staging' |
132 | | - analysis-type: 'webpack' |
133 | | - analysis-file-contents: ${{ steps.get-stats.outputs.spa }} |
134 | | - file-name-filter: '.min.js' |
135 | | - traverse: false |
136 | 100 |
|
137 | 101 | # Jobs for workflow_dispatch events |
138 | 102 |
|
@@ -189,6 +153,49 @@ jobs: |
189 | 153 | Checking merge of (${{ fromJSON(needs.find-pull-request.outputs.pull-request-target).head_sha }}) into [${{ fromJSON(needs.find-pull-request.outputs.pull-request-target).base_ref }}](https://github.com/newrelic/newrelic-browser-agent/compare/${{ fromJSON(needs.find-pull-request.outputs.pull-request-target).head_sha }}..${{ fromJSON(needs.find-pull-request.outputs.pull-request-target).base_sha }}) (${{ fromJSON(needs.find-pull-request.outputs.pull-request-target).base_sha }}) |
190 | 154 | comment_tag: <!-- browser_agent pull request checks --> |
191 | 155 |
|
| 156 | + report-build-size: |
| 157 | + name: Report build size |
| 158 | + if: github.event_name == 'workflow_dispatch' |
| 159 | + needs: find-pull-request |
| 160 | + runs-on: ubuntu-latest |
| 161 | + steps: |
| 162 | + - name: Get local stats |
| 163 | + id: get-stats |
| 164 | + run: | |
| 165 | + rum=$(cat ../../build/nr-rum-standard.stats.json); ; echo "rum=$rum" >> $GITHUB_OUTPUT; |
| 166 | + full=$(cat ../../build/nr-full-standard.stats.json); ; echo "full=$full" >> $GITHUB_OUTPUT; |
| 167 | + spa=$(cat ../../build/nr-spa-standard.stats.json); ; echo "spa=$spa" >> $GITHUB_OUTPUT; |
| 168 | + - name: Report rum size to NR |
| 169 | + uses: metal-messiah/webpack-build-size-action |
| 170 | + with: |
| 171 | + nr-api-key: ${{ secrets.INTERNAL_STAGING_INGEST_LICENSE_KEY }} |
| 172 | + nr-account-id: '550352' |
| 173 | + nr-env: 'staging' |
| 174 | + analysis-type: 'webpack' |
| 175 | + analysis-file-contents: ${{ steps.get-stats.outputs.rum }} |
| 176 | + file-name-filter: '.min.js' |
| 177 | + traverse: false |
| 178 | + - name: Report full size to NR |
| 179 | + uses: metal-messiah/webpack-build-size-action |
| 180 | + with: |
| 181 | + nr-api-key: ${{ secrets.INTERNAL_STAGING_INGEST_LICENSE_KEY }} |
| 182 | + nr-account-id: '550352' |
| 183 | + nr-env: 'staging' |
| 184 | + analysis-type: 'webpack' |
| 185 | + analysis-file-contents: ${{ steps.get-stats.outputs.full }} |
| 186 | + file-name-filter: '.min.js' |
| 187 | + traverse: false |
| 188 | + - name: Report spa size to NR |
| 189 | + uses: metal-messiah/webpack-build-size-action |
| 190 | + with: |
| 191 | + nr-api-key: ${{ secrets.INTERNAL_STAGING_INGEST_LICENSE_KEY }} |
| 192 | + nr-account-id: '550352' |
| 193 | + nr-env: 'staging' |
| 194 | + analysis-type: 'webpack' |
| 195 | + analysis-file-contents: ${{ steps.get-stats.outputs.spa }} |
| 196 | + file-name-filter: '.min.js' |
| 197 | + traverse: false |
| 198 | + |
192 | 199 | wdio-coverage: |
193 | 200 | name: WDIO coverage |
194 | 201 | if: github.event_name == 'workflow_dispatch' |
|
0 commit comments