Skip to content

Commit

Permalink
chore: do not exit when committing a merge (#96)
Browse files Browse the repository at this point in the history
  • Loading branch information
JessicaSachs authored Jan 12, 2022
1 parent 2fafe7b commit 31ad732
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion scripts/verifyCommit.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,9 @@ const releaseRE = /^v\d/;
const commitRE =
/^(revert: )?(feat|fix|docs|dx|refactor|perf|test|workflow|build|ci|chore|types|wip|release|deps)(\(.+\))?: .{1,50}/;

if (!releaseRE.test(msg) && !commitRE.test(msg)) {
const isMergeCommit = msg.startsWith('Merge remote-tracking-branch');

if (!isMergeCommit && !releaseRE.test(msg) && !commitRE.test(msg)) {
console.log();
console.error(
` ${colors.bgRed(colors.white(' ERROR '))} ${colors.red(
Expand Down

0 comments on commit 31ad732

Please sign in to comment.