chore: 🔖 release new versions #52
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: PR Title Check | |
on: | |
pull_request: | |
types: [opened, edited, synchronize, reopened] | |
jobs: | |
check-pr-title: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check PR title | |
env: | |
PR_TITLE: ${{ github.event.pull_request.title }} | |
run: | | |
if ! echo "$PR_TITLE" | grep -E "^(fix|feat|chore|docs)(\([a-z-]+\))?: (🔖 )?[a-z].+[^.]$"; then | |
echo "❌ PR title '$PR_TITLE' does not match the required format" | |
echo "Required format: type(scope): subject" | |
echo "Examples:" | |
echo " feat: add new feature" | |
echo " fix(core): fix bug" | |
echo " docs: update README" | |
exit 1 | |
fi | |
echo "✅ PR title format is valid" |