js-code-detector 0.0.41 → 0.0.42

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.
@@ -36,7 +36,12 @@ var userAliasGetter = (cwd, appData) => {
36
36
  };
37
37
  };
38
38
  async function umi4SetUp({ targetDirPath }) {
39
- import_utils.logger.info(`正在安装 @umijs/max@ 并执行 setup 脚本...`);
39
+ import_utils.logger.info(`正在删除 yarn.lock 文件...`);
40
+ const yarnLockPath = (0, import_path.join)(targetDirPath, "yarn.lock");
41
+ if ((0, import_fs.existsSync)(yarnLockPath)) {
42
+ await import_utils.execa.execa(`mv ${yarnLockPath} ${(0, import_path.join)(targetDirPath, "yarn.lock.bak")}`, { shell: true });
43
+ }
44
+ import_utils.logger.info(`正在安装 @umijs/max 并执行 setup 脚本...`);
40
45
  const shellExeResult = await import_utils.execa.execa(`cd ${targetDirPath} && yarn remove @umijs/max && yarn add @umijs/max && npx max setup`, { shell: true });
41
46
  const tsconfig = await import_utils.tsconfigPaths.loadConfig(targetDirPath);
42
47
  let appData = { config: null };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "js-code-detector",
3
- "version": "0.0.41",
3
+ "version": "0.0.42",
4
4
  "description": "",
5
5
  "main": "dist/cjs/index.js",
6
6
  "types": "dist/cjs/index.d.ts",