ci: benchmark result upload condition

This commit is contained in:
LongYinan 2020-10-14 22:08:16 +08:00
parent 03dff2575c
commit 70b2113985
No known key found for this signature in database
GPG key ID: C3666B7FC82ADAD7

View file

@ -1,6 +1,9 @@
name: Benchmark
on:
push:
branches:
- master
pull_request:
jobs:
@ -62,12 +65,20 @@ jobs:
- name: Store benchmark result
uses: rhysd/github-action-benchmark@v1
if: github.ref == 'refs/heads/master'
with:
tool: 'benchmarkjs'
output-file-path: bench.txt
comment-on-alert: true
github-token: ${{ secrets.GH_TOKEN }}
auto-push: true
- name: Store benchmark result
uses: rhysd/github-action-benchmark@v1
if: github.ref != 'refs/heads/master'
with:
tool: 'benchmarkjs'
output-file-path: bench.txt
github-token: ${{ secrets.GH_TOKEN }}
comment-always: true
- name: Clear the cargo caches