Skip to content

Commit

Permalink
Add turbo summary artifact for swc builds (vercel#50857)
Browse files Browse the repository at this point in the history
This adds uploading the turbo run summaries for our publish builds so we
can debug cache misses there easier the same as the new build_reusable
workflow.
  • Loading branch information
ijjk authored and hydRAnger committed Jun 12, 2023
1 parent 30d5377 commit 89d46b9
Showing 1 changed file with 15 additions and 3 deletions.
18 changes: 15 additions & 3 deletions .github/workflows/build_and_deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -259,13 +259,19 @@ jobs:
datadog-ci metric --no-fail --level pipeline --metrics "turbopack.bytesize.$FILENAME:$BYTESIZE"
done
- name: Upload artifact
- name: Upload swc artifact
if: ${{ needs.build.outputs.isRelease == 'true' }}
uses: actions/upload-artifact@v3
with:
name: next-swc-binaries
path: packages/next-swc/native/next-swc.*.node

- name: Upload turbo summary artifact
uses: actions/upload-artifact@v3
with:
name: turbo run summary
path: .turbo/runs

build-wasm:
needs: build
strategy:
Expand Down Expand Up @@ -302,12 +308,18 @@ jobs:
run: node scripts/normalize-version-bump.js

- name: Build
run: turbo run build-wasm -- --target ${{ matrix.target }} --features tracing/release_max_level_info
run: turbo run build-wasm --summarize -- --target ${{ matrix.target }} --features tracing/release_max_level_info

- name: Add target to folder name
run: '[[ -d "packages/next-swc/crates/wasm/pkg" ]] && mv packages/next-swc/crates/wasm/pkg packages/next-swc/crates/wasm/pkg-${{ matrix.target }} || ls packages/next-swc/crates/wasm'

- name: Upload artifact
- name: Upload turbo summary artifact
uses: actions/upload-artifact@v3
with:
name: turbo run summary
path: .turbo/runs

- name: Upload swc artifact
uses: actions/upload-artifact@v3
with:
name: wasm-binaries
Expand Down

0 comments on commit 89d46b9

Please sign in to comment.