Skip to content

chore: synced file(s) with ecmwf-actions/reusable-workflows #99

chore: synced file(s) with ecmwf-actions/reusable-workflows

chore: synced file(s) with ecmwf-actions/reusable-workflows #99

name: PR Workflow Check
on:
pull_request_target:
paths:
- ".github/**"
jobs:
check:
if: ${{ github.event.pull_request.head.repo.fork }}
runs-on: ubuntu-latest
steps:
- name: Comment PR
uses: actions/github-script@v7
with:
script: |
github.rest.issues.createComment({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
body: `> [!CAUTION]
> This pull request contains changes to GitHub workflows!
> Proceed with caution and if not sure, contact your GitHub admin.`
})
- run: |
::error::PR originating from a fork changes a Github workflow!
exit 1