From 21f9e8d7bb8b28f52d61bfa47e9c0404a62cc303 Mon Sep 17 00:00:00 2001 From: Eason chiu <76670758@qq.com> Date: Fri, 18 Jun 2021 15:05:14 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=F0=9F=90=9B=20fix=20verify=20commit?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- scripts/verify-commit-msg.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/verify-commit-msg.js b/scripts/verify-commit-msg.js index bf3cfac..5414a69 100644 --- a/scripts/verify-commit-msg.js +++ b/scripts/verify-commit-msg.js @@ -9,7 +9,7 @@ const commitRE = /^(revert: )?(feat|fix|polish|docs|style|refactor|perf|test|wor console.log(`Commit: ${chalk.bgRed.white(msg)}`); -if (!commitRE.test(msg) && packageJson.version !== msg) { +if (!commitRE.test(msg) && packageJson.version !== msg && !/^v/.test(msg)) { console.log(); console.error(` ${chalk.bgRed.white(' ERROR ')} 无效的提交信息`); process.exit(1);