diff --git a/src/rules-configs.js b/src/rules-configs.js index cfaa5c5..0efd2ea 100644 --- a/src/rules-configs.js +++ b/src/rules-configs.js @@ -19,7 +19,7 @@ export const rulesConfig = [ }, { id: 'MissingSpace', - regex: /^(?:chore|docs|feat|fix|perf|refactor|style|test)?(.+)?:(?(?!\s))(.+)?/d, + regex: /^(?:chore|docs|feat|fix|perf|refactor|style|test|build)?(.+)?:(?(?!\s))(.+)?/d, color: 'white', errorMessage: 'Space after the colon is required.', }, @@ -37,7 +37,7 @@ export const rulesConfig = [ }, { id: 'CharacterAfterScopeBeforeColon', - regex: /^(?:chore|docs|feat|fix|perf|refactor|style|test)(?:.+)?(?:(?:\([-A-Za-z0-9_ ]+\)|\(\))(?:!)?)(?.+)?:(.+)?/d, + regex: /^(?:chore|docs|feat|fix|perf|refactor|style|test|build)(?:.+)?(?:(?:\([-A-Za-z0-9_ ]+\)|\(\))(?:!)?)(?.+)?:(.+)?/d, color: 'yellow', errorMessage: 'Unexpected character before the colon in the commit message.', }, @@ -49,19 +49,19 @@ export const rulesConfig = [ }, { id: 'CharacterBetweenTypeAndScope', - regex: /^(?:chore|docs|feat|fix|perf|refactor|style|test)(?.+)(?:(?:\([-A-Za-z0-9_ ]*\))|(\(\)))(.+)?:(.+)?/d, + regex: /^(?:chore|docs|feat|fix|perf|refactor|style|test|build)(?.+)(?:(?:\([-A-Za-z0-9_ ]*\))|(\(\)))(.+)?:(.+)?/d, color: 'cyan', errorMessage: 'Unexpected character between commit type and scope.', }, { id: 'CharacterBetweenTypeAndColon', - regex: /^(?:chore|docs|feat|fix|perf|refactor|style|test)(?!(?:.*)(\([-A-Za-z0-9_ ]+\)|\(\)))(?:!?|!?(?.+)):(?:.+)?/d, + regex: /^(?:chore|docs|feat|fix|perf|refactor|style|test|build)(?!(?:.*)(\([-A-Za-z0-9_ ]+\)|\(\)))(?:!?|!?(?.+)):(?:.+)?/d, color: 'blue', errorMessage: 'Unexpected character between commit type and colon.', }, { id: 'UnknownType', - regex: /^(?!(?:chore|docs|feat|fix|perf|refactor|style|test))(\s+)?\b(?!(?:chore|docs|feat|fix|perf|refactor|style|test)\b)(?[-A-Za-z0-9_ ]+)\b(?=.*:)/d, + regex: /^(?!(?:chore|docs|feat|fix|perf|refactor|style|test|build))(\s+)?\b(?!(?:chore|docs|feat|fix|perf|refactor|style|test|build)\b)(?[-A-Za-z0-9_ ]+)\b(?=.*:)/d, color: 'blue', errorMessage: 'Unrecognized commit type used.', },