Skip to content

Commit d3051d6

Browse files
committed
Update benchmark workflow to collect results
1 parent 8689d5b commit d3051d6

File tree

2 files changed

+30
-1
lines changed

2 files changed

+30
-1
lines changed

.github/workflows/update.yml renamed to .github/workflows/benchmark.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Update Benchmarks
1+
name: Benchmark
22
on:
33
workflow_dispatch:
44
schedule:

.github/workflows/benchmarks.yml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: Benchmark
2+
on:
3+
workflow_dispatch:
4+
push:
5+
branches:
6+
- main
7+
paths:
8+
- 'src/AI.Benchmarks/BenchmarkDotNet.Artifacts/results/AI.Benchmarks.ModelPerformance-report-full-compressed.json'
9+
jobs:
10+
benchmark:
11+
runs-on: ubuntu-latest
12+
permissions:
13+
# deployments permission to deploy GitHub pages website
14+
deployments: write
15+
# contents permission to update benchmark contents in gh-pages branch
16+
contents: write
17+
steps:
18+
- uses: actions/checkout@v4
19+
- uses: actions/setup-go@v4
20+
with:
21+
go-version: "stable"
22+
# gh-pages branch is updated and pushed automatically with extracted benchmark data
23+
- uses: benchmark-action/github-action-benchmark@v1
24+
with:
25+
tool: 'benchmarkdotnet'
26+
output-file-path: 'src/AI.Benchmarks/BenchmarkDotNet.Artifacts/results/AI.Benchmarks.ModelPerformance-report-full-compressed.json'
27+
github-token: ${{ secrets.GITHUB_TOKEN }}
28+
# Push and deploy GitHub pages branch automatically
29+
auto-push: true

0 commit comments

Comments
 (0)