microfetch/.github/workflows/hotpath-comment.yml
Workflow config file is invalid. Please check your config file: yaml: line 36: mapping values are not allowed in this context
NotAShelf 353b78e688
Some checks failed
hotpath-comment.yml / ci: fix hotpath-comment usage (push) Failing after 0s
ci: fix hotpath-comment usage
Signed-off-by: NotAShelf <raf@notashelf.dev>
Change-Id: Idc163948f012efb07fc7a6a952af54b36a6a6964
2025-11-18 00:08:00 +03:00

49 lines
1.3 KiB
YAML

name: Hotpath Comment
on:
workflow_run:
workflows: ["Hotpath Profile"]
types:
- completed
permissions:
pull-requests: write
jobs:
comment:
runs-on: ubuntu-latest
if: ${{ github.event.workflow_run.conclusion == 'success' }}
steps:
- name: Download profiling results
uses: actions/download-artifact@v4
with:
name: hotpath-results
github-token: ${{ secrets.GITHUB_TOKEN }}
run-id: ${{ github.event.workflow_run.id }}
- name: Read PR number
id: pr
run: echo "number=$(cat pr_number.txt)" >> $GITHUB_OUTPUT
- name: Setup Rust
uses: actions-rust-lang/setup-rust-toolchain@v1
- name: Install hotpath CLI
run: cargo install hotpath
- name: Post timing comparison comment
run: |
hotpath profile-pr \
--head-metrics head-timing.json \
--base-metrics base-timing.json \
--github-token ${{ secrets.GITHUB_TOKEN }} \
--pr-number ${{ steps.pr.outputs.number }}
- name: Post allocation comparison comment
run: |
hotpath profile-pr \
--head-metrics head-alloc.json \
--base-metrics base-alloc.json \
--github-token ${{ secrets.GITHUB_TOKEN }} \
--pr-number ${{ steps.pr.outputs.number }}