chore: fix release comment #1
Workflow file for this run
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: "Continuous Integrations" | |
| on: | |
| pull_request: | |
| types: [opened, synchronize, reopened] | |
| jobs: | |
| validate-pr-title-conventional: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Check PR title for conventional commits | |
| uses: actions/github-script@v6 | |
| with: | |
| github-token: ${{ github.token }} | |
| script: | | |
| const prTitle = context.payload.pull_request.title; | |
| // Conventional commits regex: type(scope?): description | |
| const conventionalRegex = /^(feat|fix|chore|docs|style|refactor|perf|test|ci)(\([a-z0-9\-]+\))?: .+/; | |
| if (!conventionalRegex.test(prTitle)) { | |
| core.setFailed( | |
| `PR title "${prTitle}" is not in conventional commit format.\n` + | |
| `Example: "feat(android): add new validation function"` | |
| ); | |
| } else { | |
| console.log("PR title follows conventional commit format ✅"); | |
| } | |
| ci: | |
| uses: ./.github/workflows/reusable_ci.yml |