aboutsummaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorJess <[email protected]>2022-01-12 08:53:14 -0500
committerGitHub <[email protected]>2022-01-12 08:53:14 -0500
commit31ad7328805486d9bda05b9b507fa02335ef24b0 (patch)
treead4df55a1f57a582d5bfecc1d58199078a9dcee2 /scripts
parent2fafe7bdf0dba2452b99f2d6bbbebeb0845762ad (diff)
downloadfaker-31ad7328805486d9bda05b9b507fa02335ef24b0.tar.xz
faker-31ad7328805486d9bda05b9b507fa02335ef24b0.zip
chore: do not exit when committing a merge (#96)
Diffstat (limited to 'scripts')
-rw-r--r--scripts/verifyCommit.ts4
1 files changed, 3 insertions, 1 deletions
diff --git a/scripts/verifyCommit.ts b/scripts/verifyCommit.ts
index 2584cc37..65dd0b3d 100644
--- a/scripts/verifyCommit.ts
+++ b/scripts/verifyCommit.ts
@@ -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(