Skip to content

Commit

Permalink
fix(ci): make the workflow checkout the forked repository and be more…
Browse files Browse the repository at this point in the history
… strict
  • Loading branch information
gagik committed Feb 20, 2025
1 parent 2b839a9 commit 1ce6902
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion .github/workflows/test-and-build-from-fork.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ permissions:
jobs:
test-and-build:
name: Test and Build
if: github.event.pull_request.user.login == 'dependabot[bot]' || github.event.pull_request.head.repo.full_name != github.repository
if: github.event.pull_request.user.login == 'dependabot[bot]' && github.event.pull_request.head.repo.full_name != github.repository

strategy:
matrix:
Expand All @@ -24,6 +24,8 @@ jobs:
uses: actions/checkout@v4
with:
fetch-depth: 0
ref: ${{github.event.pull_request.head.ref}}
repository: ${{github.event.pull_request.head.repo.full_name}}

- name: Setup Node.js Environment
uses: actions/setup-node@v4
Expand Down

0 comments on commit 1ce6902

Please sign in to comment.