Skip to content

Commit e6038e7

Browse files
authored
ci: update workflows for nodejs projects (#130)
1 parent 784a52c commit e6038e7

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

.github/workflows/if-nodejs-release.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,15 @@ on:
1919
jobs:
2020

2121
test-nodejs:
22+
# We just check the message of first commit as there is always just one commit because we squash into one before merging
23+
# "commits" contains array of objects where one of the properties is commit "message"
24+
# Release workflow will be skipped if release conventional commits are not used
25+
if: |
26+
startsWith( github.repository, 'asyncapi/' ) &&
27+
(startsWith( github.event.commits[0].message , 'fix:' ) ||
28+
startsWith( github.event.commits[0].message, 'fix!:' ) ||
29+
startsWith( github.event.commits[0].message, 'feat:' ) ||
30+
startsWith( github.event.commits[0].message, 'feat!:' ))
2231
name: Test NodeJS release on ${{ matrix.os }}
2332
runs-on: ${{ matrix.os }}
2433
strategy:

0 commit comments

Comments
 (0)