Skip to content

Commit 7f0ed00

Browse files
committed
Add a check to ensure that the publish workflow only runs for the master branch
1 parent b378fec commit 7f0ed00

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

.github/workflows/publish-workflow.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,9 @@ jobs:
99
name: Publish
1010
runs-on: ubuntu-latest
1111
steps:
12+
- name: Cancel if not the master branch # workaround has `on` doesn't have this filter
13+
run: exit 1
14+
if: github.ref != 'refs/heads/master'
1215
- uses: actions/checkout@v1
1316
- name: Use Node.js 12.x
1417
uses: actions/setup-node@v1

0 commit comments

Comments
 (0)