ci: only dedupe dependencies if they affect bundle size (#23736)

This commit is contained in:
Daniel Roe 2023-10-18 10:06:15 +01:00 committed by GitHub
parent 271349d7f0
commit 633ef85dd9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -23,10 +23,6 @@ jobs:
- name: Install dependencies
run: pnpm install
- name: Dedupe dependencies
if: ${{ contains(github.head_ref, 'renovate') }}
run: pnpm dedupe
- name: Build (stub)
run: pnpm build:stub
@ -39,7 +35,18 @@ jobs:
- name: Run build
run: pnpm build
- name: Assert bundle size (renovate)
if: ${{ contains(github.head_ref, 'renovate') }}
run: pnpm vitest run bundle
- name: Update bundle size (renovate)
if: failure()
run: |
pnpm vitest run bundle -u
pnpm dedupe
- name: Update bundle size
if: ${{ !contains(github.head_ref, 'renovate') }}
run: pnpm vitest run bundle -u
- uses: autofix-ci/action@d3e591514b99d0fca6779455ff8338516663f7cc