RiemaLabs / modular-indexer-light

A fully user-verified execution layer for Bitcoin's meta-protocols. (light indexer)
https://eprint.iacr.org/2024/408
57 stars 21 forks source link

ci: enable commit checker in github action #42

Closed WadeZhouRiema closed 4 months ago

WadeZhouRiema commented 4 months ago

Enable commit checker in github action. Commit message should be like "feat: xxx", "ci: xxx", "fix: xxx", etc. Otherwise the github action will fail.

ghost commented 4 months ago

I found a better approach to the commitlint:

npx commitlint --from=main --extends @commitlint/config-conventional -V

It means:

So we could simply extend our make ci with:

.PHONY: ci
ci:
    # The existing rules here...
    # Install the dependencies...
    npm i -g @commitlint/{cli,config-conventional}
    npx commitlint --from=main --extends @commitlint/config-conventional -V

Since for most of the time our CI is triggered on PRs into the main branch, and locally we could run the same command for dry-runs.

Closing this PR for a better approach.