ci: fix size-report (#11203)

This commit is contained in:
Fernando Fernández 2024-06-23 15:43:40 +02:00 committed by GitHub
parent 0126cfff9d
commit 423b462e59
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 10 additions and 14 deletions

View File

@ -13,6 +13,7 @@ permissions:
env: env:
PUPPETEER_SKIP_DOWNLOAD: 'true' PUPPETEER_SKIP_DOWNLOAD: 'true'
COMMENT_MARKER: <!-- VUE_CORE_SIZE -->
jobs: jobs:
size-report: size-report:
@ -52,20 +53,15 @@ jobs:
path: temp/size-prev path: temp/size-prev
if_no_artifact_found: warn if_no_artifact_found: warn
- name: Compare size - name: Prepare report
run: pnpm tsx scripts/size-report.ts > size-report.md run: |
pnpm tsx scripts/size-report.ts > size-report.md
- name: Read Size Report echo '${{ env.COMMENT_MARKER }}' >> size-report.md
id: size-report
uses: juliangruber/read-file-action@v1
with:
path: ./size-report.md
- name: Create Comment - name: Create Comment
uses: actions-cool/maintain-one-comment@v3 uses: thollander/actions-comment-pull-request@v2.5.0
with: with:
token: ${{ secrets.GITHUB_TOKEN }} GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
body: | filePath: size-report.md
${{ steps.size-report.outputs.content }} comment_tag: ${{ env.COMMENT_MARKER }}
<!-- VUE_CORE_SIZE --> pr_number: ${{ github.event.workflow_run.pull_requests[0].number }}
body-include: '<!-- VUE_CORE_SIZE -->'