deeke-script-app 1.0.3 → 1.0.4

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.
Files changed (2) hide show
  1. package/init +2 -2
  2. package/package.json +1 -1
package/init CHANGED
@@ -7,12 +7,12 @@ function generateFiles(answers) {
7
7
  const projectPath = process.cwd(); // 输出:/Users/username/project
8
8
 
9
9
  const files = fs.readdirSync(projectPath)
10
- if (files.length > 2 || !files.includes('package.json') || !files.includes('package-lock.json')) {
10
+ if (files.length > 3 || !files.includes('package.json') || !files.includes('package-lock.json') || !files.includes('node_modules')) {
11
11
  throw new Error('请清空当前文件夹,并重新运行命令');
12
12
  }
13
13
 
14
14
  const entries = fs.readdirSync(__dirname, { withFileTypes: true });
15
- const excludeFiles = ['node_modules', 'init.js', 'test.js', '.gitignore']; // 需排除的文件名列表
15
+ const excludeFiles = ['node_modules', 'init', 'test.js']; // 需排除的文件名列表
16
16
 
17
17
  const filteredEntries = entries.filter(entry =>
18
18
  !excludeFiles.includes(entry.name)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "deeke-script-app",
3
- "version": "1.0.3",
3
+ "version": "1.0.4",
4
4
  "description": "DeekeScript应用",
5
5
  "main": "src/index.ts",
6
6
  "scripts": {