standards-cli 1.0.1 → 1.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "standards-cli",
3
- "version": "1.0.1",
3
+ "version": "1.0.2",
4
4
  "description": "一键初始化前端项目提交规范链路(cz-git + commitlint + husky + lint-staged)",
5
5
  "type": "module",
6
6
  "bin": {
@@ -136,8 +136,8 @@ async function generateConfigFiles(pkg) {
136
136
  }
137
137
 
138
138
  // .lintstagedrc.cjs - 根据是否有 eslint/prettier 选择模板
139
- const hasLintTools = hasLintTools(pkg);
140
- const lintstagedTemplate = hasLintTools
139
+ const hasLintToolsInstalled = hasLintTools(pkg);
140
+ const lintstagedTemplate = hasLintToolsInstalled
141
141
  ? "require('standards-cli/templates/lint-staged/config.cjs')"
142
142
  : "require('standards-cli/templates/lint-staged/config-simple.cjs')";
143
143
  const lintstagedrcCreated = await writeFileIfMissing(