refactor: mf-6329 rename $MATIC to $POL #13065
Workflow file for this run
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: "Check Milestone" | |
on: | |
pull_request: | |
types: | |
- opened | |
- edited | |
- synchronize | |
- milestoned | |
- demilestoned | |
branchs: | |
- 'develop' | |
- 'release/*' | |
- 'hotfix/*' | |
merge_group: | |
types: [checks_requested] | |
permissions: | |
contents: read | |
jobs: | |
check: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check Milestone | |
if: "(github.event.pull_request && github.event.pull_request.milestone == null) && github.event.pull_request.title != 'docs(i18n): sync i18n files from Crowdin'" | |
run: | | |
echo "Please set a milestone." | |
exit 1 | |
- name: Check target branch of develop | |
if: ${{ github.event.pull_request && github.base_ref == 'develop' && github.event.pull_request.milestone != null }} # merge to develop | |
run: | | |
if [[ ${{ github.event.pull_request.milestone.title }} =~ ^[0-9]+.[0-9]+.0$ ]] | |
then | |
echo "Well Done" | |
else | |
echo "Don't patch on the develop branch." | |
exit 1 | |
fi | |
- name: Check target branch of release/* | |
if: ${{ github.event.pull_request && startsWith(github.base_ref, 'release/') }} # merge to release/* | |
run: | | |
if [[ ${{ github.event.pull_request.milestone.title }} =~ ^[0-9]+.[0-9]+.0$ ]] | |
then | |
echo "Well Done" | |
else | |
echo "Don't patch on a pre-release branch." | |
fi | |
- name: Check target branch of hotfix/* | |
if: ${{ github.event.pull_request && startsWith(github.base_ref, 'hotfix/') }} # merge to hotfix/* | |
run: | | |
if [[ ${{ github.event.pull_request.milestone.title }} =~ ^[0-9]+.[0-9]+.0$ ]] | |
then | |
echo "A hotfix branch only allows patch requests." | |
else | |
echo "Well Done" | |
fi |