feat(worker-build): auto-install nightly prereqs for --panic-unwind (… #3
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CodSpeed Benchmarks | |
| on: | |
| push: | |
| branches: | |
| - "main" | |
| pull_request: | |
| # `workflow_dispatch` allows CodSpeed to trigger backtest | |
| # performance analysis in order to generate initial data. | |
| workflow_dispatch: | |
| env: | |
| BENCH_RESULT: /tmp/benchmark_results.json | |
| permissions: | |
| contents: read | |
| id-token: write | |
| jobs: | |
| benchmarks: | |
| name: Run benchmarks | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| submodules: true | |
| - uses: dtolnay/rust-toolchain@1.87.0 | |
| with: | |
| targets: wasm32-unknown-unknown | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: '22' | |
| - uses: Swatinem/rust-cache@v2 | |
| with: | |
| key: cargo-bench-${{ hashFiles('**/Cargo.lock') }} | |
| - name: Build wasm-bindgen and worker-build | |
| run: npm run build | |
| - name: Install benchmark dependencies | |
| working-directory: benchmark | |
| run: npm install | |
| - name: Build benchmark | |
| working-directory: benchmark | |
| run: node --run build | |
| - name: Run benchmarks | |
| uses: CodSpeedHQ/action@v4 | |
| with: | |
| mode: walltime | |
| run: cd benchmark && node run.js && node codspeed-convert.js $BENCH_RESULT |