File tree Expand file tree Collapse file tree 1 file changed +3
-12
lines changed Expand file tree Collapse file tree 1 file changed +3
-12
lines changed Original file line number Diff line number Diff line change 28
28
jobs :
29
29
deploy-target :
30
30
runs-on : ubuntu-latest
31
- # TL;DR: Only trigger for push events or pull_request events from forks.
32
- #
33
- # PRs from forks will only trigger a pull_request event where sha and workflow_sha are different.
34
- # PRs from vercel/next.js will trigger push and pull_request event. Both events
35
- # events from vercel/next.js, will have the sha and workflow_sha.
36
- # We only need one run so skip the pull_request event.
37
- # The pull_request event would not give us a sha that we can use to query this
38
- # workflow which is required for vercel-packages to work.
31
+ # Don't trigger this job on `pull_request` events from upstream branches.
32
+ # Those would already run this job on the `push` event
33
+ if : ${{ github.event_name != 'pull_request' || github.event.repository.fork }}
39
34
outputs :
40
35
value : ${{ steps.deploy-target.outputs.value }}
41
36
steps :
42
- - run : |
43
- echo "event_name=${{ github.event_name }}"
44
- echo "sha=${{ github.sha }}"
45
- echo "workflow_sha=${{ github.workflow_sha }}"
46
37
- uses : actions/checkout@v4
47
38
with :
48
39
fetch-depth : 1
You can’t perform that action at this time.
0 commit comments