commitlint.config.mjs 730 B

12345678910111213141516171819202122232425262728293031323334
  1. /** @type {import("@commitlint/types").UserConfig} */
  2. export default {
  3. ignores: [(commit) => commit.includes('init')],
  4. extends: ['@commitlint/config-conventional'],
  5. rules: {
  6. 'body-leading-blank': [2, 'always'],
  7. 'footer-leading-blank': [1, 'always'],
  8. 'header-max-length': [2, 'always', 108],
  9. 'subject-empty': [2, 'never'],
  10. 'type-empty': [2, 'never'],
  11. 'subject-case': [0],
  12. 'type-enum': [
  13. 2,
  14. 'always',
  15. [
  16. 'feat',
  17. 'fix',
  18. 'perf',
  19. 'style',
  20. 'docs',
  21. 'test',
  22. 'refactor',
  23. 'build',
  24. 'ci',
  25. 'chore',
  26. 'revert',
  27. 'wip',
  28. 'workflow',
  29. 'types',
  30. 'release',
  31. ],
  32. ],
  33. },
  34. };