From 0a1836796f792c1ec05b3378fba1deef3f904990 Mon Sep 17 00:00:00 2001 From: zhangrengao Date: Wed, 21 Sep 2022 18:50:31 +0800 Subject: [PATCH] Fix preview mode abc file not work Signed-off-by: zhangrengao Change-Id: I91ed8817dd62b250f01c28a0de5c4a5f80e8c66c --- compiler/src/gen_abc_plugin.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/compiler/src/gen_abc_plugin.ts b/compiler/src/gen_abc_plugin.ts index 30dc6c0..cf67942 100644 --- a/compiler/src/gen_abc_plugin.ts +++ b/compiler/src/gen_abc_plugin.ts @@ -841,7 +841,7 @@ function writeHashJson(): void { process.exitCode = FAIL; break; } - if (!fs.existsSync(abcFile)) { + if (process.env.cachePath !== undefined) { mkdirsSync(path.dirname(abcFile)); fs.copyFileSync(cacheAbcFilePath, abcFile); } -- Gitee