Skip to content

Commit

Permalink
Skip external help integration from forks
Browse files Browse the repository at this point in the history
PRs from forks do not have access to the help repo.
  • Loading branch information
lcartey committed Dec 27, 2024
1 parent 89bd9b4 commit 81ff0c0
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion .github/workflows/code-scanning-pack-gen.yml
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,8 @@ jobs:
- name: Checkout external help files
id: checkout-external-help-files
# Forks do not have access to an appropriate token for the help files
if: !github.event.pull_request.head.repo.fork
uses: actions/checkout@v4
with:
ssh-key: ${{ secrets.CODEQL_CODING_STANDARDS_HELP_KEY }}
Expand All @@ -88,7 +90,7 @@ jobs:
path: external-help-files

- name: Include external help files
if: steps.checkout-external-help-files.outcome == 'success'
if: !github.event.pull_request.head.repo.fork && steps.checkout-external-help-files.outcome == 'success'
run: |
pushd external-help-files
find . -name '*.md' -exec rsync -av --relative {} "$GITHUB_WORKSPACE" \;
Expand Down

0 comments on commit 81ff0c0

Please sign in to comment.