diff --git a/.github/workflows/pr_build.yml b/.github/workflows/pr_build.yml index aa69aea31..d905095e4 100644 --- a/.github/workflows/pr_build.yml +++ b/.github/workflows/pr_build.yml @@ -126,3 +126,18 @@ jobs: - if: matrix.test-target == 'java' name: Java test steps uses: ./.github/actions/java-test + check-pr-title: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Check PR title + env: + PR_TITLE: ${{ github.event.pull_request.title }} + run: | + if ! echo $PR_TITLE | grep -Eq '^(\w+)(\(.+\))?: .+$'; then + echo "PR title does not follow conventional commit style." + echo "Please use a title in the format: type: message, or type(scope): message" + echo "Example: feat: Add support for sort-merge join" + exit 1 + fi +