feat: 新增代码检查脚本

This commit is contained in:
lanyeeee
2026-02-27 06:00:49 +08:00
parent 7065a4ce73
commit b8aeff7cb2
4 changed files with 13 additions and 3 deletions

View File

@@ -1,7 +1,10 @@
<!-- <!--
PR请提交至 develop 分支 PR请提交至 develop 分支
提交前请先运行 pnpm format 以保证代码格式正确 提交前请先
1. 运行 pnpm format 以保证代码格式正确
2. 运行 pnpm check 并确认无报错
如果想新加一个功能,请先开个 issue 或 discussion 讨论一下,避免无效工作 如果想新加一个功能,请先开个 issue 或 discussion 讨论一下,避免无效工作

View File

@@ -85,7 +85,10 @@ pnpm tauri build
**PR请提交至`develop`分支** **PR请提交至`develop`分支**
**提交前请先运行`pnpm format`以保证代码格式正确** **提交前请先**
1. 运行`pnpm format`以保证代码格式正确
2. 运行`pnpm check`并确认无报错
**如果想新加一个功能,请先开个`issue`或`discussion`讨论一下,避免无效工作** **如果想新加一个功能,请先开个`issue`或`discussion`讨论一下,避免无效工作**

View File

@@ -20,4 +20,7 @@ export default defineConfig([
}, },
}, },
}, },
{
ignores: ['src/bindings.ts', 'src/vite-env.d.ts'],
},
]) ])

View File

@@ -8,7 +8,8 @@
"build": "vue-tsc --noEmit && vite build", "build": "vue-tsc --noEmit && vite build",
"preview": "vite preview", "preview": "vite preview",
"tauri": "tauri", "tauri": "tauri",
"format": "prettier . -w && cd src-tauri && cargo fmt --all" "format": "prettier . -w && cd src-tauri && cargo fmt --all",
"check": "prettier . --check && eslint -c eslint.config.js --max-warnings=0 src && vue-tsc --noEmit && cd src-tauri && cargo clippy -- -D warnings"
}, },
"dependencies": { "dependencies": {
"@phosphor-icons/vue": "^2.2.1", "@phosphor-icons/vue": "^2.2.1",