Skip to content

Add CI test that fails if a PR is issued to main #12

Add CI test that fails if a PR is issued to main

Add CI test that fails if a PR is issued to main #12

Workflow file for this run

name: check PR branch
on: [pull_request]
jobs:
check-PR-branch:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Get PR target branch
id: get-target-branch
run: bash .github/workflows/get_pr_target_branch.sh
- name: No PRs should target the main branch; use development instead
if: ${{ steps.get-target-branch.outputs.target_branch == 'main' }}
run: exit 1