0
Fork 0
mirror of https://github.com/logto-io/logto.git synced 2024-12-23 20:33:16 -05:00
logto/.github/workflows/commitlint.yml
renovate[bot] ae5284b1d3
chore(deps): update pnpm to v9 (#5727)
* chore(deps): update pnpm to v9

* ci: fix alteration

---------

Co-authored-by: Gao Sun <gao@silverhand.io>
2024-05-09 08:42:31 +00:00

33 lines
902 B
YAML

name: Commitlint
on:
push:
branches:
- 'push-action/**'
pull_request:
types: [opened, edited, synchronize, reopened]
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
jobs:
lint-commits:
if: github.event_name == 'pull_request'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup Node and pnpm
uses: silverhand-io/actions-node-pnpm-run-steps@v4
with:
pnpm-version: 9
- name: Commitlint
# Credit to https://stackoverflow.com/a/67365254/12514940
run: npx commitlint --from ${{ github.event.pull_request.base.sha }} --to ${{ github.event.pull_request.head.sha }} --verbose
- name: Commitlint on PR title
run: echo '${{ github.event.pull_request.title }}' | npx commitlint