From f78254f11dd7a8e725ce1fd7507a09d1de97a741 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=8E=8B=E9=9D=92?= Date: Mon, 10 Oct 2022 17:03:24 +0800 Subject: [PATCH] =?UTF-8?q?api=20check=E9=97=AE=E9=A2=98=E5=AE=9A=E4=BD=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: 王青 --- build-tools/api_check_plugin/entry.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/build-tools/api_check_plugin/entry.js b/build-tools/api_check_plugin/entry.js index ef4efc25a0..5d03e2948b 100644 --- a/build-tools/api_check_plugin/entry.js +++ b/build-tools/api_check_plugin/entry.js @@ -24,12 +24,14 @@ function checkEntry(url) { execSync("cd interface/sdk-js/build-tools/api_check_plugin && npm install"); const { scanEntry } = require(path.resolve(__dirname, "./src/api_check_plugin")); result = scanEntry(url); + const content = fs.readFileSync(path.resolve(__dirname, "./Result.txt"), "utf-8"); + result += `mdFilePath = ${url}, content = ${content}` writeResultFile(result, path.resolve(__dirname, "./Result.txt"), {}); const { removeDir } = require(path.resolve(__dirname, "./src/utils")); removeDir(path.resolve(__dirname, "node_modules")); } catch (error) { // catch error - result = error; + result = 'ERROR'; } } checkEntry(process.argv[2]); -- Gitee