From 5c074e6fe8a03eb653ea1fe52887d87cdcf54a87 Mon Sep 17 00:00:00 2001 From: shaw Date: Wed, 20 May 2026 17:09:57 +0800 Subject: [PATCH] ci: restrict cla workflow to upstream repo --- .github/workflows/cla.yml | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/.github/workflows/cla.yml b/.github/workflows/cla.yml index 67c8d6e9..e009e2db 100644 --- a/.github/workflows/cla.yml +++ b/.github/workflows/cla.yml @@ -15,8 +15,11 @@ permissions: jobs: cla-check: if: | - github.event_name == 'issue_comment' || - (github.event_name == 'pull_request_target' && github.event.action != 'closed') + github.repository == 'Wei-Shaw/sub2api' && + ( + github.event_name == 'issue_comment' || + (github.event_name == 'pull_request_target' && github.event.action != 'closed') + ) runs-on: ubuntu-latest steps: - name: "CLA Assistant" @@ -45,7 +48,11 @@ jobs: custom-allsigned-prcomment: "All contributors have signed the CLA. ✅" cla-lock: - if: github.event_name == 'pull_request_target' && github.event.action == 'closed' && github.event.pull_request.merged == true + if: | + github.repository == 'Wei-Shaw/sub2api' && + github.event_name == 'pull_request_target' && + github.event.action == 'closed' && + github.event.pull_request.merged == true runs-on: ubuntu-latest steps: - name: "Lock merged PR"