Skip to content

Commit 38516e4

Browse files
balazsorban44natew
authored andcommitted
chore: do not run lock/stale actions on forks (vercel#34053)
The lock and stale actions will always fail on fork repos since they are using secrets that are not shared with the fork workflow runs. This PR addresses that by limiting the lock and stale actions to bail out on fork repo workflow runs. ## Bug - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Errors have helpful link attached, see `contributing.md` ## Feature - [ ] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR. - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Documentation added - [ ] Telemetry added. In case of a feature if it's used or not. - [ ] Errors have helpful link attached, see `contributing.md` ## Documentation / Examples - [ ] Make sure the linting passes by running `yarn lint`
1 parent 9e8b626 commit 38516e4

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

.github/workflows/lock.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ concurrency:
1616
jobs:
1717
action:
1818
runs-on: ubuntu-latest
19+
if: github.repository_owner == 'vercel'
1920
steps:
2021
- uses: dessant/lock-threads@v3
2122
with:

.github/workflows/stale.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ on:
88
jobs:
99
stale:
1010
runs-on: ubuntu-latest
11+
if: github.repository_owner == 'vercel'
1112
steps:
1213
- uses: actions/stale@v4
1314
id: stale
@@ -21,4 +22,4 @@ jobs:
2122
days-before-pr-close: -1
2223
days-before-pr-stale: -1
2324
exempt-issue-labels: 'blocked,must,should,keep'
24-
operation-per-run: 300 # 1 operation per 100 issues, the rest is to label/comment/close
25+
operations-per-run: 300 # 1 operation per 100 issues, the rest is to label/comment/close

0 commit comments

Comments
 (0)