diff --git a/.github/workflows/target-main.yml b/.github/workflows/target-main.yml new file mode 100644 index 000000000..3ca6f116e --- /dev/null +++ b/.github/workflows/target-main.yml @@ -0,0 +1,18 @@ +on: + pull_request_target: + types: [opened] + +jobs: + comment: + if: ${{ github.base_ref }} != "master" + runs-on: ubuntu-latest + steps: + - uses: actions/github-script@v6 + with: + script: | + github.rest.issues.createComment({ + issue_number: context.issue.number, + owner: context.repo.owner, + repo: context.repo.repo, + body: '⚠️ This pull request does not target the master branch.' + })