Skip to content

chore: fix release comment #1

chore: fix release comment

chore: fix release comment #1

Workflow file for this run

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