- run: pnpm benchmark:prod | tee ./benchmarks/internal/output.txt
- - name: Store production benchmark result
- uses: benchmark-action/github-action-benchmark@v1
- with:
- name: Internal benchmark
- tool: 'benchmarkjs'
- output-file-path: ./benchmarks/internal/output.txt
- github-token: ${{ secrets.BENCHMARK_RESULTS_TOKEN }}
- auto-push: true
- alert-threshold: '200%'
- comment-on-alert: true
- fail-on-alert: true
- max-items-in-chart: 100
- gh-repository: 'github.com/poolifier/benchmark-results'
+ run: |
+ bencher run \
+ --if-branch "$GITHUB_REF_NAME" \
+ --else-if-branch "$GITHUB_BASE_REF" \
+ --else-if-branch master \
+ --hash "$GITHUB_SHA" \
+ --err \
+ --github-actions ${{ secrets.GITHUB_TOKEN }} \
+ "pnpm benchmark:prod"