fix(analytics): keep polling alive when fetch throws a Throwable (SDK-86) #50
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: PR Title Check | |
| on: | |
| pull_request: | |
| types: [opened, edited, synchronize, reopened] | |
| permissions: | |
| contents: read | |
| jobs: | |
| check-title: | |
| name: Validate PR title | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4 | |
| with: | |
| sparse-checkout: .github/modules.json | |
| sparse-checkout-cone-mode: false | |
| - name: Check PR title format | |
| env: | |
| PR_TITLE: ${{ github.event.pull_request.title }} | |
| run: | | |
| MODULE_LIST=$(jq -r 'keys | join("|")' .github/modules.json) | |
| SCOPED_PATTERN="^(feat|fix|chore)\((${MODULE_LIST}|all)\): .+" | |
| UNSCOPED_PATTERN="^(release|chore): .+" | |
| if [[ "$PR_TITLE" =~ $SCOPED_PATTERN ]] || [[ "$PR_TITLE" =~ $UNSCOPED_PATTERN ]]; then | |
| echo "PR title is valid: $PR_TITLE" | |
| exit 0 | |
| fi | |
| echo "PR title does not match the required format." | |
| echo "" | |
| echo " Got: $PR_TITLE" | |
| echo "" | |
| echo "Expected one of:" | |
| echo " feat(<module>): description" | |
| echo " fix(<module>): description" | |
| echo " chore(<module>): description" | |
| echo " chore: description" | |
| echo " release: description" | |
| echo "" | |
| echo "Valid modules: ${MODULE_LIST//|/, }" | |
| exit 1 |