Skip to content

Commit 64d313b

Browse files
committed
update: add workflow_dispatch trigger to test FluxMLBenchmarks.jl more conveniently
1 parent 1af37ee commit 64d313b

File tree

1 file changed

+14
-3
lines changed

1 file changed

+14
-3
lines changed

.github/workflows/BenchmarkTrigger.yml

Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,16 +3,27 @@ name: Benchmark Trigger
33
on:
44
pull_request:
55
types: [ labeled ]
6+
workflow_dispatch:
7+
inputs:
8+
pr_id:
9+
type: string
10+
description: id of the pull request that triggers this workflow
11+
target_url:
12+
type: string
13+
description: url of target
14+
baseline_url:
15+
type: string
16+
description: url of baseline
617

718
jobs:
819
benchmark_trigger:
920
if: ${{ github.event.label.name == 'benchmark' }}
1021
runs-on: ubuntu-latest
1122
env:
1223
REPOSITORY: ${{ github.event.repository.full_name }}
13-
PR_ID: ${{ github.event.pull_request.number }}
14-
TARGET_URL: ${{ format("{0}#{1}", github.event.pull_request.head.html_url, github.event.pull_request.head.sha) }}
15-
BASELINE_URL: ${{ format("{0}#{1}"", github.event.pull_request.base.repo.html_url, github.event.pull_request.base.sha) }}
24+
PR_ID: ${{ github.event.inputs.pr_id || github.event.pull_request.number }}
25+
TARGET_URL: ${{ github.event.inputs.target_url || format("{0}#{1}", github.event.pull_request.head.html_url, github.event.pull_request.head.sha) }}
26+
BASELINE_URL: ${{ github.event.inputs.baseline_url || format("{0}#{1}"", github.event.pull_request.base.repo.html_url, github.event.pull_request.base.sha) }}
1627
steps:
1728
- uses: benc-uk/workflow-dispatch@v1
1829
with:

0 commit comments

Comments
 (0)