Skip to content

Commit 1aec7d9

Browse files
committed
some fixes
1 parent 212338b commit 1aec7d9

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

.github/workflows/perf-test.yml

+5-4
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,14 @@ on:
88

99
jobs:
1010
build:
11+
name: Build ${{ matrix.name }}
1112
runs-on: ubuntu-latest
1213
strategy:
1314
matrix:
1415
include:
1516
- commit: ${{ github.sha }}
1617
name: current
17-
- commit: ${{ github.event_name == 'pull_request' && github.base_ref || github.event.before }}
18+
- commit: ${{ github.event_name == 'pull_request' && github.event.pull_request.base.sha || github.event.before }}
1819
name: previous
1920
steps:
2021
- name: Checkout ${{ matrix.name }}
@@ -36,7 +37,7 @@ jobs:
3637
with:
3738
name: ${{ matrix.name }}
3839
path: target/release/cpp-linter
39-
40+
4041
benchmark:
4142
name: Measure Performance Difference
4243
needs: [build]
@@ -49,14 +50,15 @@ jobs:
4950
ref: v1.8.1
5051
- name: Download built binaries
5152
uses: actions/download-artifact@v4
53+
- run: ls previous current
54+
- run: chmod +x ./previous/cpp-linter && chmod +x ./current/cpp-linter
5255
- name: Install cargo-binstall
5356
uses: cargo-bins/cargo-binstall@main
5457
- name: Install hyperfine
5558
run: cargo binstall -y hyperfine
5659
- name: Run hyperfine tool
5760
run: >-
5861
hyperfine
59-
--shell=default
6062
--warmup 1
6163
--runs 5
6264
--style color
@@ -74,4 +76,3 @@ jobs:
7476
python-version: 3.x
7577
- name: Annotate summary
7678
run: python .github/workflows/bench.py "${{ runner.temp }}/benchmark.json"
77-

0 commit comments

Comments
 (0)