Skip to content

Commit d3b1387

Browse files
radoeringabn
authored andcommitted
ci: update workflow to allow to test workflow changes
1 parent 83f5cf1 commit d3b1387

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

.github/workflows/deploy-preview.yml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
11
name: "Deploy Preview"
22

33
on:
4-
push:
5-
branches-ignore:
6-
- main
4+
pull_request:
5+
# allow repository maintainers to modify and test workflow
6+
paths:
7+
- ".github/workflows/deploy-preview.yaml"
78
pull_request_target:
89
# enable runs for this workflow when labeled as safe only
910
# prevent execution when the workflow itself is modified from a fork
@@ -21,7 +22,7 @@ jobs:
2122
runs-on: ubuntu-latest
2223
if: |
2324
(github.event_name == 'pull_request_target' && contains(github.event.pull_request.labels.*.name, 'safe'))
24-
|| (github.event_name == 'push' && github.event.push.repository.full_name == github.repository)
25+
|| (github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.repository)
2526
steps:
2627
- name: Checkout
2728
uses: actions/checkout@v3

0 commit comments

Comments
 (0)