@biuxiu/codegen 0.1.6 → 0.1.8

Sign up to get free protection for your applications and to get access to all the features.
Files changed (2) hide show
  1. package/dist/gen-type.js +5 -3
  2. package/package.json +2 -2
package/dist/gen-type.js CHANGED
@@ -36,9 +36,11 @@ const genLuaTypes = async (path) => {
36
36
  readPath: (0, import_path.resolve)(__dirname, `../sources/${t}-type.txt`)
37
37
  }));
38
38
  moveList.forEach((m) => {
39
- (0, import_promises.readFile)(m.readPath, "utf-8").then((content) => {
40
- (0, import_promises.writeFile)(m.writePath, content);
41
- });
39
+ if (!(0, import_fs.existsSync)(m.writePath)) {
40
+ (0, import_promises.readFile)(m.readPath, "utf-8").then((content) => {
41
+ (0, import_promises.writeFile)(m.writePath, content);
42
+ });
43
+ }
42
44
  });
43
45
  const settingPath = (0, import_path.join)(vscodePath, "settings.json");
44
46
  if ((0, import_fs.existsSync)(settingPath)) {
package/package.json CHANGED
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "name": "@biuxiu/codegen",
3
- "version": "0.1.6",
3
+ "version": "0.1.8",
4
4
  "description": "代码生成工具",
5
- "main": "index.js",
5
+ "main": "dist/index.js",
6
6
  "scripts": {
7
7
  "test:dev": "tsx scripts/dev.ts",
8
8
  "test:rm": "tsx scripts/dev.ts -d",