refactor(home): reduce text; people hate reading #60
This file contains 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 Git Flow | |
on: | |
pull_request: | |
branches: | |
- main | |
jobs: | |
check_base_branch: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Fail if PR is from develop branch | |
run: | | |
if [[ "${{ github.event.pull_request.head.ref }}" =~ ^release/.* ]]; then | |
exit 0 | |
elif [[ "${{ github.event.pull_request.head.ref }}" =~ ^hotfix/.* ]]; then | |
exit 0 | |
else | |
echo "Error: Merging from a branch that doesn't start with 'release/' into the 'main' branch is not allowed." | |
exit 1 | |
fi |