66 push :
77 pull_request :
88 workflow_dispatch :
9+ inputs :
10+ commit_id :
11+ description : ' Commit ID (optional)'
12+ required : false
913 schedule :
1014 - cron : " 0 12 * * *"
1115
5054 steps :
5155 - name : Check out repo
5256 uses : actions/checkout@v4
57+ with :
58+ ref : ${{ github.event_name == 'workflow_dispatch' && inputs.commit_id || github.sha }}
5359 - name : Build on Windows
5460 if : startsWith(matrix.image, 'windows')
5561 run : |
8995 steps :
9096 - name : Check out repo
9197 uses : actions/checkout@v4
98+ with :
99+ ref : ${{ github.event_name == 'workflow_dispatch' && inputs.commit_id || github.sha }}
92100 - uses : actions/setup-node@v4
93101 with :
94102 node-version : ' 18.x'
@@ -108,6 +116,8 @@ jobs:
108116 steps :
109117 - name : Check out repo
110118 uses : actions/checkout@v4
119+ with :
120+ ref : ${{ github.event_name == 'workflow_dispatch' && inputs.commit_id || github.sha }}
111121 - uses : actions/setup-node@v4
112122 with :
113123 node-version : ' 18.x'
@@ -130,6 +140,8 @@ jobs:
130140 steps :
131141 - name : Check out repo
132142 uses : actions/checkout@v4
143+ with :
144+ ref : ${{ github.event_name == 'workflow_dispatch' && inputs.commit_id || github.sha }}
133145 - name : Build R package
134146 run : |
135147 cd R
@@ -150,6 +162,8 @@ jobs:
150162 steps :
151163 - name : Check out repo
152164 uses : actions/checkout@v4
165+ with :
166+ ref : ${{ github.event_name == 'workflow_dispatch' && inputs.commit_id || github.sha }}
153167 - name : Set up Python
154168 uses : actions/setup-python@v5
155169 with :
@@ -173,6 +187,8 @@ jobs:
173187 steps :
174188 - name : Check out repo
175189 uses : actions/checkout@v4
190+ with :
191+ ref : ${{ github.event_name == 'workflow_dispatch' && inputs.commit_id || github.sha }}
176192 - name : Set up Python
177193 uses : actions/setup-python@v5
178194 with :
@@ -218,6 +234,8 @@ jobs:
218234 steps :
219235 - name : Check out repo
220236 uses : actions/checkout@v4
237+ with :
238+ ref : ${{ github.event_name == 'workflow_dispatch' && inputs.commit_id || github.sha }}
221239 - name : Set up Python
222240 uses : actions/setup-python@v5
223241 with :
@@ -251,6 +269,8 @@ jobs:
251269 steps :
252270 - name : Check out repo
253271 uses : actions/checkout@v4
272+ with :
273+ ref : ${{ github.event_name == 'workflow_dispatch' && inputs.commit_id || github.sha }}
254274 - name : Set up Python
255275 uses : actions/setup-python@v5
256276 with :
@@ -337,6 +357,8 @@ jobs:
337357 steps :
338358 - name : Check out repo
339359 uses : actions/checkout@v4
360+ with :
361+ ref : ${{ github.event_name == 'workflow_dispatch' && inputs.commit_id || github.sha }}
340362 - name : Set up Python
341363 uses : actions/setup-python@v5
342364 with :
@@ -415,6 +437,8 @@ jobs:
415437 steps :
416438 - name : Check out repo
417439 uses : actions/checkout@v4
440+ with :
441+ ref : ${{ github.event_name == 'workflow_dispatch' && inputs.commit_id || github.sha }}
418442 - name : Set up Python
419443 uses : actions/setup-python@v5
420444 with :
@@ -509,6 +533,8 @@ jobs:
509533 steps :
510534 - name : Check out repo
511535 uses : actions/checkout@v4
536+ with :
537+ ref : ${{ github.event_name == 'workflow_dispatch' && inputs.commit_id || github.sha }}
512538 - name : Set up Python
513539 uses : actions/setup-python@v5
514540 with :
@@ -563,6 +589,8 @@ jobs:
563589 steps :
564590 - name : Check out repo
565591 uses : actions/checkout@v4
592+ with :
593+ ref : ${{ github.event_name == 'workflow_dispatch' && inputs.commit_id || github.sha }}
566594 - name : Check C++ code formatting with clang-format
567595 id : check_cpp
568596 continue-on-error : true
@@ -592,6 +620,8 @@ jobs:
592620 steps :
593621 - name : Check out repo
594622 uses : actions/checkout@v4
623+ with :
624+ ref : ${{ github.event_name == 'workflow_dispatch' && inputs.commit_id || github.sha }}
595625 - name : Check python matches black format
596626 id : check_python
597627 continue-on-error : true
0 commit comments