From b9a26af5b08d3d92a6c38fd90e023bc4706f19eb Mon Sep 17 00:00:00 2001
From: shuishen <1109946754@qq.com>
Date: Mon, 29 Sep 2025 14:22:30 +0800
Subject: [PATCH] feat:一些基础文件格式化处理

---
 scripts/verify-commit.js |   23 +++++++++++------------
 1 files changed, 11 insertions(+), 12 deletions(-)

diff --git a/scripts/verify-commit.js b/scripts/verify-commit.js
index 96cdb28..29a52eb 100644
--- a/scripts/verify-commit.js
+++ b/scripts/verify-commit.js
@@ -3,26 +3,25 @@
  * @link https://github.com/toplenboren/simple-git-hooks
  * @see 参考:https://github.com/vuejs/vue-next/blob/master/.github/commit-convention.md
  */
-import { readFileSync } from 'node:fs';
-import path from 'node:path';
-import process from 'node:process';
-import pico from 'picocolors';
+import { readFileSync } from 'node:fs'
+import path from 'node:path'
+import process from 'node:process'
+import pico from 'picocolors'
 
-const msgPath = path.resolve('.git/COMMIT_EDITMSG');
-const msg = readFileSync(msgPath, 'utf-8').trim();
+const msgPath = path.resolve('.git/COMMIT_EDITMSG')
+const msg = readFileSync(msgPath, 'utf-8').trim()
 
 const commitRE
-    = /^(?:revert: )?(?:feat|fix|docs|dx|style|refactor|perf|test|workflow|build|ci|chore|types|wip|mod|release|strengthen)(?:\(.+\))?: .{1,50}/;
+  = /^(?:revert: )?(?:feat|fix|docs|dx|style|refactor|perf|test|workflow|build|ci|chore|types|wip|mod|release|strengthen)(?:\(.+\))?: .{1,50}/
 
 if (!commitRE.test(msg)) {
-  console.log(pico.yellow(`\n提交的信息: ${msg}\n`));
+  console.log(pico.yellow(`\n提交的信息: ${msg}\n`))
   console.error(
     `  ${pico.white(pico.bgRed(' 格式错误 '))} ${pico.red(
       '无效的提交信息格式.',
-    )}\n\n${
-      pico.red('  正确的提交消息格式. 例如:\n\n')
+    )}\n\n${pico.red('  正确的提交消息格式. 例如:\n\n')
     }    ${pico.green('feat: add a new feature')}\n`
     + `    ${pico.green('fix: fixed an bug')}`,
-  );
-  process.exit(1);
+  )
+  process.exit(1)
 }

--
Gitblit v1.9.3