Skip to content

Commit d483da6

Browse files
committed
Add a ref for workflow dispatch
1 parent 87e247e commit d483da6

1 file changed

Lines changed: 7 additions & 5 deletions

File tree

.github/workflows/wheels.yml

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,5 @@
11
name: Publish sdist and wheels
22

3-
env:
4-
SOURCE_REF_TO_BUILD: main
5-
63
on:
74
schedule:
85
# 01:01 UTC every Monday and Thursday.
@@ -16,6 +13,11 @@ on:
1613
- main
1714
workflow_dispatch:
1815
inputs:
16+
ref:
17+
description: The scikit-learn branch, tag, or commit to build
18+
required: false
19+
default: main
20+
type: string
1921
environment:
2022
description: Which PyPI environment to upload to, if any
2123
required: true
@@ -151,7 +153,7 @@ jobs:
151153
uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
152154
with:
153155
repository: scikit-learn/scikit-learn
154-
ref: ${{ env.SOURCE_REF_TO_BUILD }}
156+
ref: ${{ github.event.inputs.ref || 'main' }}
155157
path: scikit-learn-src
156158
persist-credentials: false
157159

@@ -202,7 +204,7 @@ jobs:
202204
uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
203205
with:
204206
repository: scikit-learn/scikit-learn
205-
ref: ${{ env.SOURCE_REF_TO_BUILD }}
207+
ref: ${{ github.event.inputs.ref || 'main' }}
206208
path: scikit-learn-src
207209
persist-credentials: false
208210

0 commit comments

Comments
 (0)