feature: inhancing workflows security and codeowners permissions #27
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: Enforce source branch | |
| on: | |
| pull_request: | |
| branches: [main] | |
| jobs: | |
| check-source: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Check source branch | |
| if: github.head_ref != 'develop' | |
| env: | |
| HEAD_REF: ${{ github.head_ref }} | |
| run: | | |
| echo "::error::PRs to main must come from the develop branch, not '${HEAD_REF}'" | |
| exit 1 |