Skip to content

Rules ​

body-case ​

  • condition: body is in case value

  • rule: always

  • value

    text
    'lower-case'
  • possible values

    js
    [
      "lower-case", // default
      "upper-case", // UPPERCASE
      "camel-case", // camelCase
      "kebab-case", // kebab-case
      "pascal-case", // PascalCase
      "sentence-case", // Sentence case
      "snake-case", // snake_case
      "start-case", // Start Case
    ];

body-empty ​

  • condition: body is empty
  • rule: never

body-full-stop ​

  • condition: body ends with value

  • rule: never

  • value

    text
    '.'

body-leading-blank ​

  • condition: body begins with blank line
  • rule: always

body-max-length ​

  • condition: body has value or less characters

  • rule: always

  • value

    text
    Infinity

body-max-line-length ​

  • condition: body lines have value or less characters, or contain a URL

  • rule: always

  • value

    text
    Infinity

body-min-length ​

  • condition: body has value or more characters

  • rule: always

  • value

    text
    0

breaking-change-exclamation-mark ​

  • condition: Either both or neither header has an exclamation mark before the : marker and a line in footer matches the regular expression ^BREAKING[ -]CHANGE:
  • rule: always

NOTE

This rule enforces that breaking changes are marked by both a ! in the header and BREAKING CHANGE in the footer. The behavior is that of an XNOR operation:

  • It passes when either both are present or both are not.
  • It fails when one is present and the other is not.
  • condition: footer is empty
  • rule: never
  • condition: footer begins with blank line
  • rule: always
  • condition: footer has value or less characters