diff --git a/.github/workflows/run-ci.yml b/.github/workflows/run-ci.yml index 617d674..1c050e8 100644 --- a/.github/workflows/run-ci.yml +++ b/.github/workflows/run-ci.yml @@ -2,6 +2,25 @@ name: CI run-name: Check ${{ github.ref_name }} by @${{ github.actor }} on: pull_request jobs: + commit-message: + name: Check commit message format + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v4 + with: + fetch-depth: 0 + - name: Setup Node.js + uses: actions/setup-node@v4 + with: + node-version: '20.x' + - name: Install commitlint + run: | + npm install @commitlint/config-conventional @commitlint/cli + echo "export default {extends: ['@commitlint/config-conventional']};" > commitlint.config.js + - name: Lint commit messages + run: npx commitlint --from=$(git rev-parse origin/${{ github.base_ref}}) --to=HEAD + linters: name: Run linters runs-on: ubuntu-latest