Add script (and CI check) to check / update the autogenerated pioasm outputs #56
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Make sure PRs target the develop branch | |
on: | |
pull_request_target: | |
# By default, pull_request_target gets write permissions to the repo - this prevents that | |
permissions: | |
pull-requests: write | |
jobs: | |
check-branch: | |
if: github.event.pull_request.base.ref == 'master' | |
runs-on: ubuntu-latest | |
steps: | |
- name: Add comment | |
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: 'Please do not submit against `master`, use `develop` instead' | |
}) | |
- name: Throw error | |
run: | | |
echo "::error title=wrong-branch::Please do not submit against 'master', use 'develop' instead" | |
exit 1 |