Skip to content

Commit 2a13d0e

Browse files
authored
fear: cancel-in-progress to use input variable
1 parent 4cc04ca commit 2a13d0e

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

.github/workflows/build-node-python.yml

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,9 @@ on:
8484
required: false
8585
type: boolean
8686
default: false
87+
cancel_in_progress:
88+
type: boolean
89+
default: true
8790
timeout:
8891
description: "Timeout for each job in minutes."
8992
type: number
@@ -126,7 +129,7 @@ jobs:
126129
if: ${{ (!inputs.cypress_enable || (!inputs.cypress_run_because_flag && inputs.cypress_run_because_branch != 'true')) && (!inputs.playwright_enable || (!inputs.playwright_run_because_flag && inputs.playwright_run_because_branch != 'true')) }}
127130
concurrency:
128131
group: "node-${{ github.workflow }}-${{ github.ref || github.head_ref }}-${{ inputs.branch }}"
129-
cancel-in-progress: true
132+
cancel-in-progress: ${{ fromJSON(inputs.cancel_in_progress) }}
130133
permissions:
131134
id-token: write
132135
contents: write
@@ -168,7 +171,7 @@ jobs:
168171
if: ${{ (!inputs.cypress_enable || (!inputs.cypress_run_because_flag && inputs.cypress_run_because_branch != 'true')) && (!inputs.playwright_enable || (!inputs.playwright_run_because_flag && inputs.playwright_run_because_branch != 'true')) }}
169172
concurrency:
170173
group: "python-${{ github.workflow }}-${{ github.ref || github.head_ref }}-${{ inputs.branch }}"
171-
cancel-in-progress: true
174+
cancel-in-progress: ${{ fromJSON(inputs.cancel_in_progress) }}
172175
permissions:
173176
id-token: write
174177
contents: write
@@ -207,7 +210,7 @@ jobs:
207210
if: ${{ inputs.cypress_enable && (inputs.cypress_run_because_flag || inputs.cypress_run_because_branch == 'true') }}
208211
concurrency:
209212
group: "node-python-cypress-${{ github.workflow }}-${{ github.ref || github.head_ref }}-${{ inputs.branch }}"
210-
cancel-in-progress: true
213+
cancel-in-progress: ${{ fromJSON(inputs.cancel_in_progress) }}
211214
permissions:
212215
id-token: write
213216
contents: write
@@ -348,7 +351,7 @@ jobs:
348351
if: ${{ inputs.playwright_enable && (inputs.playwright_run_because_flag || inputs.playwright_run_because_branch == 'true') }}
349352
concurrency:
350353
group: "node-python-playwright-${{ github.workflow }}-${{ github.ref || github.head_ref }}-${{ inputs.branch }}"
351-
cancel-in-progress: true
354+
cancel-in-progress: ${{ fromJSON(inputs.cancel_in_progress) }}
352355
permissions:
353356
id-token: write
354357
contents: write

0 commit comments

Comments
 (0)