Skip to content

Commit daf2cc8

Browse files
committed
CI: Always build releases, just don't store or create them if there is no tag
1 parent b8ccd88 commit daf2cc8

File tree

1 file changed

+18
-43
lines changed

1 file changed

+18
-43
lines changed

.github/workflows/gs1encoders.yml

Lines changed: 18 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -257,19 +257,8 @@ jobs:
257257

258258
build-release-windows:
259259

260-
if: startsWith(github.ref, 'refs/tags/')
261-
262260
needs:
263-
- ci-gcc
264-
- ci-clang
265261
- ci-msvc
266-
- ci-macos
267-
- ci-scan-build
268-
- ci-java
269-
- ci-wasm
270-
- ci-jsonly
271-
- ci-ios-app
272-
- ci-android-app
273262

274263
runs-on: windows-2019
275264

@@ -291,6 +280,7 @@ jobs:
291280
7z a gs1encoders-windows-libs.zip gs1encoders.h gs1encoders.lib gs1encoders.dll ../../../../gs1-syntax-dictionary.txt
292281
293282
- name: Store Windows development libs
283+
if: startsWith(github.ref, 'refs/tags/')
294284
uses: actions/upload-artifact@v2
295285
with:
296286
name: windows-libs
@@ -302,6 +292,7 @@ jobs:
302292
7z a gs1encoders-windows-console-app.zip gs1encoders-app.exe gs1encoders.dll ../../../../gs1-syntax-dictionary.txt
303293
304294
- name: Store Windows console app
295+
if: startsWith(github.ref, 'refs/tags/')
305296
uses: actions/upload-artifact@v2
306297
with:
307298
name: windows-console-app
@@ -313,6 +304,7 @@ jobs:
313304
7z a gs1encoders-windows-gui-app.zip gs1encoders-dotnet-app.exe ../../gs1encoders.dll ../../../../../../c-lib/gs1-syntax-dictionary.txt
314305
315306
- name: Store Windows GUI app
307+
if: startsWith(github.ref, 'refs/tags/')
316308
uses: actions/upload-artifact@v2
317309
with:
318310
name: windows-gui-app
@@ -321,19 +313,9 @@ jobs:
321313

322314
build-release-linux:
323315

324-
if: startsWith(github.ref, 'refs/tags/')
325-
326316
needs:
327317
- ci-gcc
328318
- ci-clang
329-
- ci-msvc
330-
- ci-macos
331-
- ci-scan-build
332-
- ci-java
333-
- ci-wasm
334-
- ci-jsonly
335-
- ci-ios-app
336-
- ci-android-app
337319

338320
runs-on: ubuntu-latest
339321

@@ -350,26 +332,16 @@ jobs:
350332
tar cvzf gs1encoders-linux-app.tgz gs1encoders-linux.bin gs1-syntax-dictionary.txt
351333
352334
- name: Store Linux build
335+
if: startsWith(github.ref, 'refs/tags/')
353336
uses: actions/upload-artifact@v2
354337
with:
355338
name: linux-app
356339
path: src/c-lib/build/gs1encoders-linux-app.tgz
357340

358341
build-release-wasm:
359342

360-
if: startsWith(github.ref, 'refs/tags/')
361-
362343
needs:
363-
- ci-gcc
364-
- ci-clang
365-
- ci-msvc
366-
- ci-macos
367-
- ci-scan-build
368-
- ci-java
369344
- ci-wasm
370-
- ci-jsonly
371-
- ci-ios-app
372-
- ci-android-app
373345

374346
runs-on: ubuntu-latest
375347

@@ -387,6 +359,7 @@ jobs:
387359
tar cvzf gs1encoders-wasm-app.tgz gs1encoder-wasm.wasm gs1encoder-wasm.mjs gs1encoder.mjs example.html example.mjs example.node.mjs
388360
389361
- name: Store WASM build
362+
if: startsWith(github.ref, 'refs/tags/')
390363
uses: actions/upload-artifact@v2
391364
with:
392365
name: wasm-app
@@ -395,19 +368,8 @@ jobs:
395368

396369
build-release-jsonly:
397370

398-
if: startsWith(github.ref, 'refs/tags/')
399-
400371
needs:
401-
- ci-gcc
402-
- ci-clang
403-
- ci-msvc
404-
- ci-macos
405-
- ci-scan-build
406-
- ci-java
407-
- ci-wasm
408372
- ci-jsonly
409-
- ci-ios-app
410-
- ci-android-app
411373

412374
runs-on: ubuntu-latest
413375

@@ -425,6 +387,7 @@ jobs:
425387
tar cvzf gs1encoders-jsonly-app.tgz gs1encoder-wasm.mjs.mem gs1encoder-wasm.mjs gs1encoder.mjs example.html example.mjs example.node.mjs
426388
427389
- name: Store JSONLY build
390+
if: startsWith(github.ref, 'refs/tags/')
428391
uses: actions/upload-artifact@v2
429392
with:
430393
name: jsonly-app
@@ -437,9 +400,21 @@ jobs:
437400

438401
create-release:
439402

403+
if: startsWith(github.ref, 'refs/tags/')
404+
440405
runs-on: ubuntu-latest
441406

442407
needs:
408+
- ci-gcc
409+
- ci-clang
410+
- ci-msvc
411+
- ci-macos
412+
- ci-scan-build
413+
- ci-java
414+
- ci-wasm
415+
- ci-jsonly
416+
- ci-ios-app
417+
- ci-android-app
443418
- build-release-linux
444419
- build-release-windows
445420
- build-release-wasm

0 commit comments

Comments
 (0)