From b99b80c18ba14cbce55c7fd10bd2f97d980cda69 Mon Sep 17 00:00:00 2001 From: George Kalpakas Date: Tue, 10 Mar 2020 23:06:38 +0200 Subject: [PATCH] fix(dev-infra): do not run the `lock-closed` GitHub action on forks (#36000) Previously, the `lock-closed` GitHub action, which runs daily and locks closed inactive issues, was run on each fork of the `angular/angular` repo. While the action is a [no-op on forks][1], it make still fail from time to time, generating a confusing notification e-mail for the fork owner. This commit configures the `lock-closed` action to only run on the main `angular/angular` repository (using the method suggested [here][2]). [1]: https://github.com/angular/dev-infra/blob/13b25d383/github-actions/lock-closed/src/main.ts#L117 [2]: https://github.community/t5/GitHub-Actions/Do-not-run-cron-workflows-in-forks/td-p/46756 PR Close #36000 --- .github/workflows/lock-closed.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/lock-closed.yml b/.github/workflows/lock-closed.yml index a8350d626d..4b88f003a7 100644 --- a/.github/workflows/lock-closed.yml +++ b/.github/workflows/lock-closed.yml @@ -7,6 +7,7 @@ on: jobs: lock_closed: + if: github.repository == 'angular/angular' runs-on: ubuntu-latest steps: - uses: angular/dev-infra/github-actions/lock-closed@66462f6