Skip to content

Commit eb2b181

Browse files
committed
fixup!: skip cancel workflow on forks
Looks like the cancel action workflow can't run on forks due to secrets. See andymckay/cancel-action#4
1 parent 27312a5 commit eb2b181

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

.github/workflows/build.yaml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,8 @@ jobs:
5252
run: yarn fmt
5353

5454
- name: Fail workflow
55-
if: failure()
55+
# Skip on forks
56+
if: (github.event.pull_request.head.repo.full_name == github.repository || github.event_name) != 'pull_request' && failure()
5657
uses: andymckay/[email protected]
5758

5859
lint-helm:
@@ -85,7 +86,8 @@ jobs:
8586
run: helm kubeval ci/helm-chart
8687

8788
- name: Fail workflow
88-
if: failure()
89+
# Skip on forks
90+
if: (github.event.pull_request.head.repo.full_name == github.repository || github.event_name) != 'pull_request' && failure()
8991
uses: andymckay/[email protected]
9092

9193
lint-ts:
@@ -131,7 +133,8 @@ jobs:
131133
run: yarn lint:ts
132134

133135
- name: Fail workflow
134-
if: failure()
136+
# Skip on forks
137+
if: (github.event.pull_request.head.repo.full_name == github.repository || github.event_name) != 'pull_request' && failure()
135138
uses: andymckay/[email protected]
136139

137140
build:

0 commit comments

Comments
 (0)