diff --git a/src/header.js b/src/header.js index 38f21d1..9b3947f 100644 --- a/src/header.js +++ b/src/header.js @@ -37,7 +37,7 @@ export function parseHeader(header) { // because the last question mark, which we totally need // eslint-disable-next-line unicorn/no-unsafe-regex - const regex = /^(\w+)(?:\((.+)\))?: (.+)$/; + const regex = /^(\w+)(?:\((.+)\))?: (.+)$/i; if (!regex.test(header)) { throw new TypeError(errorMsg); } diff --git a/src/plugins/increment.js b/src/plugins/increment.js index ee59aea..5638432 100644 --- a/src/plugins/increment.js +++ b/src/plugins/increment.js @@ -14,13 +14,13 @@ export default function increment(commit) { let isBreaking = isBreakingChange(commit); let commitIncrement = false; - if (/fix|bugfix|patch/.test(commit.header.type)) { + if (/fix|bugfix|patch/i.test(commit.header.type)) { commitIncrement = 'patch'; } - if (/feat|feature|minor/.test(commit.header.type)) { + if (/feat|feature|minor/i.test(commit.header.type)) { commitIncrement = 'minor'; } - if (/break|breaking|major/.test(commit.header.type) || isBreaking) { + if (/break|breaking|major/i.test(commit.header.type) || isBreaking) { commitIncrement = 'major'; } isBreaking = isBreaking || commitIncrement === 'major';