-
Notifications
You must be signed in to change notification settings - Fork 83
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1166 from gregdhill/chore/commit-manually
chore: commit new weights manually
- Loading branch information
Showing
1 changed file
with
8 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,7 +10,7 @@ permissions: | |
jobs: | ||
benchmark: | ||
name: Benchmark | ||
if: ${{ github.event.issue.pull_request && startsWith(github.event.comment.body, '/run_benchmarks') }} | ||
if: ${{ github.event.issue.pull_request && startsWith(github.event.comment.body, '/benchmark') }} | ||
runs-on: [self-hosted, linux] | ||
steps: | ||
- uses: actions/github-script@v6 | ||
|
@@ -37,7 +37,7 @@ jobs: | |
id: command | ||
with: | ||
result-encoding: string | ||
# /run_benchmarks CHAIN_NAME [PALLET_NAME] | ||
# /benchmark CHAIN_NAME [PALLET_NAME] | ||
script: | | ||
const [cmd, ...args] = context.payload.comment.body.split(" ") | ||
const [runtime, pallet] = args | ||
|
@@ -71,10 +71,12 @@ jobs: | |
- name: Run benchmarks | ||
run: ${{steps.command.outputs.result}} > ${{runner.temp}}/out.txt | ||
- name: Commit new weights | ||
uses: stefanzweifel/git-auto-commit-action@v4 | ||
with: | ||
commit_message: Automated weights | ||
|
||
run: | | ||
git config user.email "[email protected]" | ||
git config user.name "Interlay Bot" | ||
git add . | ||
git commit -m '${{github.event.comment.body}}' --allow-empty | ||
git push origin HEAD:${{ fromJson(steps.issue.outputs.result).ref }} | ||
- uses: actions/github-script@v6 | ||
name: Update comment | ||
with: | ||
|