File tree Expand file tree Collapse file tree 4 files changed +47
-39
lines changed
Expand file tree Collapse file tree 4 files changed +47
-39
lines changed Original file line number Diff line number Diff line change 11name : Bindings Node.js
22
33on :
4- push :
5- branches :
6- - main
7- tags :
8- - v*
9- pull_request :
10- branches :
11- - main
12- paths :
13- - " core/**"
14- - " sql/**"
15- - " driver/**"
16- - " bindings/nodejs/**"
17- - " .github/workflows/bindings.nodejs.yml"
18-
19- concurrency :
20- group : ${{ github.workflow }}-${{ github.ref }}-${{ github.event_name }}
21- cancel-in-progress : true
4+ workflow_call :
5+ inputs :
6+ publish :
7+ description : ' Whether to publish to npm'
8+ type : boolean
9+ required : false
10+ default : false
2211
2312jobs :
2413 check :
@@ -131,7 +120,7 @@ jobs:
131120 - run : make -C tests test-bindings-nodejs
132121
133122 publish :
134- if : startsWith(github.ref, 'refs/tags/v')
123+ if : inputs.publish == true
135124 needs : [build, integration]
136125 runs-on : ubuntu-latest
137126 permissions :
Original file line number Diff line number Diff line change 11name : Bindings Python
22
33on :
4- push :
5- branches :
6- - main
7- tags :
8- - v*
9- pull_request :
10- branches :
11- - main
12- paths :
13- - " core/**"
14- - " sql/**"
15- - " driver/**"
16- - " bindings/python/**"
17- - " .github/workflows/bindings.python.yml"
18-
19- concurrency :
20- group : ${{ github.workflow }}-${{ github.ref }}-${{ github.event_name }}
21- cancel-in-progress : true
4+ workflow_call :
5+ inputs :
6+ publish :
7+ description : ' Whether to publish to PyPI'
8+ type : boolean
9+ required : false
10+ default : false
2211
2312jobs :
2413 check :
@@ -208,7 +197,7 @@ jobs:
208197
209198
210199 publish :
211- if : startsWith(github.ref, 'refs/tags/v')
200+ if : inputs.publish == true
212201 needs : [check, build, integration]
213202 runs-on : ubuntu-latest
214203 permissions :
Original file line number Diff line number Diff line change 88
99concurrency :
1010 group : ${{ github.workflow }}-${{ github.ref }}-${{ github.event_name }}
11- cancel-in-progress : true
11+ cancel-in-progress : ${{ github.event_name == 'pull_request' }}
1212
1313jobs :
1414 check :
8989 - run : make -C tests test-core
9090 - run : make -C tests test-driver
9191 - run : make -C tests test-bendsql
92+
93+ bindings_python :
94+ needs : check
95+ uses : ./.github/workflows/bindings.python.yml
96+ with :
97+ publish : false
98+ secrets : inherit
99+
100+ bindings_nodejs :
101+ needs : check
102+ uses : ./.github/workflows/bindings.nodejs.yml
103+ with :
104+ publish : false
105+ secrets : inherit
Original file line number Diff line number Diff line change @@ -244,3 +244,19 @@ jobs:
244244 GH_TOKEN : ${{ github.token }}
245245 run : |
246246 gh release upload ${{ needs.check.outputs.new_version }} dist/pkg/* --clobber
247+
248+ bindings_python :
249+ needs : [check, build_linux]
250+ if : needs.check.outputs.version_changed == 'true'
251+ uses : ./.github/workflows/bindings.python.yml
252+ with :
253+ publish : true
254+ secrets : inherit
255+
256+ bindings_nodejs :
257+ needs : [check, build_linux]
258+ if : needs.check.outputs.version_changed == 'true'
259+ uses : ./.github/workflows/bindings.nodejs.yml
260+ with :
261+ publish : true
262+ secrets : inherit
You can’t perform that action at this time.
0 commit comments