Skip to content

Commit ca04cad

Browse files
authored
Automate benchmarking - removed GH_TOKEN (#749)
## Summary <!--- This is a required section; please describe the main purpose of this proposed code change. ---> GH_TOKEN removed and used github config info to push to gh-pages branch. <!--- ## Details This is an optional section; is there anything specific that reviewers should be aware of? ---> ## Testing Done <!--- This is a required section; please describe how this change was tested. ---> <!-- Replace BLANK with your device type. For example, A100-80G-PCIe Complete the following tasks before sending your PR, and replace `[ ]` with `[x]` to indicate you have done them. --> - Hardware Type: <BLANK> - [ ] run `make test` to ensure correctness - [ ] run `make checkstyle` to ensure code style - [ ] run `make test-convergence` to ensure convergence
1 parent 7b689f7 commit ca04cad

File tree

1 file changed

+12
-8
lines changed

1 file changed

+12
-8
lines changed

.github/workflows/benchmark.yml

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,14 @@ on:
44
push:
55
branches:
66
- main
7-
paths:
8-
- "src/**"
9-
- "test/**"
10-
- "benchmark/**"
7+
# paths:
8+
# - "src/**"
9+
# - "test/**"
10+
# - "benchmark/**"
1111

12+
permissions:
13+
contents: write
14+
1215
concurrency:
1316
# This causes it to cancel previous in-progress actions on the same PR / branch,
1417
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
@@ -20,13 +23,13 @@ jobs:
2023
env:
2124
MODAL_TOKEN_ID: ${{ secrets.MODAL_TOKEN_ID }}
2225
MODAL_TOKEN_SECRET: ${{ secrets.MODAL_TOKEN_SECRET }}
23-
GH_TOKEN: ${{ secrets.GH_TOKEN }}
2426
GITHUB_USERNAME: linkedin
2527
REPO_NAME: Liger-Kernel
2628
OUTPUT_DIR: benchmarks
2729
OUTPUT_FILENAME: benchmark.csv
2830
GENERATED_CSV: benchmark/data/all_benchmark_data.csv
2931

32+
3033
steps:
3134
- name: Checkout code
3235
uses: actions/checkout@v3
@@ -36,6 +39,7 @@ jobs:
3639
id: get_hash
3740
run: echo "hash=$(git rev-parse --short HEAD)" >> $GITHUB_OUTPUT
3841

42+
3943
- name: Set up Python
4044
uses: actions/setup-python@v3
4145
with:
@@ -58,7 +62,6 @@ jobs:
5862
with:
5963
ref: gh-pages
6064
path: gh-pages
61-
token: ${{ secrets.GH_TOKEN }}
6265

6366
# Step 6: Copy benchmark CSV to gh-pages directory
6467
- name: Copy generated benchmark to gh-pages
@@ -70,9 +73,10 @@ jobs:
7073
- name: Commit and push to gh-pages
7174
run: |
7275
cd gh-pages
73-
git config user.name "GitHub Action Bot"
74-
git config user.email "action@github.com"
76+
git config user.name github-actions[bot]
77+
git config user.email 41898282+github-actions[bot]@users.noreply.github.com
7578
git add .
7679
git commit -m "Add benchmark for commit ${{ steps.get_hash.outputs.hash }}" || echo "No changes to commit"
7780
git push origin gh-pages
7881
82+

0 commit comments

Comments
 (0)