uniky 1.0.25 → 1.0.26

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": "uniky",
3
- "version": "1.0.25",
3
+ "version": "1.0.26",
4
4
  "description": "uni-app 开发工具库,包含 hooks、http 请求和 vite 插件",
5
5
  "type": "module",
6
6
  "main": "./src/lib/index.ts",
@@ -124,11 +124,23 @@ export * from './plugin/index.js';
124
124
  const skillsSourceDir = join(__dirname, '..', 'src', 'plugin', '.skills');
125
125
  const skillsTargetDir = join(projectRoot, '.skills');
126
126
  if (existsSync(skillsSourceDir)) {
127
- const skillsCopied = copyDirectorySkipExisting(skillsSourceDir, skillsTargetDir);
127
+ if (!existsSync(skillsTargetDir)) {
128
+ mkdirSync(skillsTargetDir, { recursive: true });
129
+ }
130
+ const sourceFiles = readdirSync(skillsSourceDir).filter(f => statSync(join(skillsSourceDir, f)).isFile());
131
+ let skillsCopied = 0;
132
+ sourceFiles.forEach(file => {
133
+ const targetPath = join(skillsTargetDir, file);
134
+ if (!existsSync(targetPath)) {
135
+ copyFileSync(join(skillsSourceDir, file), targetPath);
136
+ skillsCopied++;
137
+ console.log(`[uniky] .skills 新增文件: ${file}`);
138
+ }
139
+ });
128
140
  if (skillsCopied > 0) {
129
141
  console.log(`[uniky] ✅ .skills 拷贝了 ${skillsCopied} 个新文件到 ${skillsTargetDir}`);
130
142
  } else {
131
- console.log(`[uniky] .skills 文件已存在,跳过拷贝`);
143
+ console.log(`[uniky] .skills 所有文件已存在,跳过拷贝`);
132
144
  }
133
145
  }
134
146
  } catch (error) {
@@ -30,7 +30,7 @@ description: 根据给出路径去创建一个uni-app 的页面
30
30
  }
31
31
  ```
32
32
 
33
- 如果路径以`pages-`开头 例如pages-order/list/query则作为子报添加到 subPackages 子模块中
33
+ 如果路径以`pages-`开头, 例如pages-order/list/query则作为子报添加到 subPackages 子模块中
34
34
 
35
35
  ```jsonc
36
36
  {