-
Notifications
You must be signed in to change notification settings - Fork 58
63 lines (50 loc) · 1.53 KB
/
bench.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
name: bench
on:
workflow_dispatch:
push:
paths-ignore:
- 'README.md'
- 'benchmark_results/**'
env:
CI: true
jobs:
build:
name: bench
strategy:
matrix:
platform: [ubuntu-latest]
runs-on: ${{ matrix.platform }}
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 1
submodules: true
- uses: actions-rs/toolchain@v1
with:
toolchain: nightly
override: true
components: rust-src
- uses: Swatinem/rust-cache@v2
- name: bench
shell: bash
run: |
wget "https://github.com/protocolbuffers/protobuf/releases/download/v23.3/protoc-23.3-linux-x86_64.zip" -O protoc.zip
unzip protoc.zip
chmod +x bin/protoc
mv bin/protoc /usr/local/bin
wget "https://github.com/google/flatbuffers/releases/download/v23.5.26/Linux.flatc.binary.clang++-12.zip" -O flatbuffers
unzip flatbuffers
chmod +x flatc
mv flatc /usr/local/bin
sudo apt-get install -y capnproto libprotobuf-dev
git config --global user.name github-actions
git config --global user.email github-actions@github.com
cargo run -p bencher
git add -A benchmark_results
git add README.md
git commit -m "[gh-actions] Update benchmarks"
- name: Push changes
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
branch: ${{ github.ref }}