From f41998ac330022cc209c359890f4e778a040e5fb Mon Sep 17 00:00:00 2001 From: touchscale <11134128+touchscale_admin@user.noreply.gitee.com> Date: Tue, 13 Jun 2023 04:33:23 +0000 Subject: [PATCH 1/3] update lib/plugins/loader.js. Signed-off-by: touchscale <11134128+touchscale_admin@user.noreply.gitee.com> --- lib/plugins/loader.js | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/plugins/loader.js b/lib/plugins/loader.js index 56f322e..59851e6 100644 --- a/lib/plugins/loader.js +++ b/lib/plugins/loader.js @@ -698,6 +698,7 @@ class PluginsLoader { /** 判断黑白名单 */ checkBlack (e) { let other = cfg.getOther() + let notice = cfg.getNotice() if (e.test) return true From 9be976499ee2a511b820f2ab0f4123c68064c186 Mon Sep 17 00:00:00 2001 From: touchscale <11134128+touchscale_admin@user.noreply.gitee.com> Date: Mon, 19 Jun 2023 01:38:02 +0000 Subject: [PATCH 2/3] add .puppeteerrc.cjs. Signed-off-by: touchscale <11134128+touchscale_admin@user.noreply.gitee.com> --- .puppeteerrc.cjs | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 .puppeteerrc.cjs diff --git a/.puppeteerrc.cjs b/.puppeteerrc.cjs new file mode 100644 index 0000000..4907718 --- /dev/null +++ b/.puppeteerrc.cjs @@ -0,0 +1,33 @@ +const os = require("os"); +const { existsSync } = require("fs"); +const arch = os.arch(); +let skipDownload = false; +let executablePath; +//win32 存在 Edge 优先选择 +if (process.platform == "win32") { + if ( + existsSync("C:/Program Files (x86)/Microsoft/Edge/Application/msedge.exe") + ) { + skipDownload = true; + executablePath = + "C:/Program Files (x86)/Microsoft/Edge/Application/msedge.exe"; + } +} else if (process.platform == "linux") { + //如果arm64架构跳过下载 + if (arch == "arm64" || arch == "aarch64") { + skipDownload = true; + } + //不管什么架构,如果存在配置则跳过下载,且配置路径 + if (existsSync("/usr/bin/chromium")) { + skipDownload = true; + executablePath = "/usr/bin/chromium"; + } +} + +/** + * @type {import("puppeteer").Configuration} + */ +module.exports = { + skipDownload, + executablePath, +}; From 263c736140d413829cf08ebdb705feba7668c7c1 Mon Sep 17 00:00:00 2001 From: touchscale <11134128+touchscale_admin@user.noreply.gitee.com> Date: Fri, 23 Jun 2023 14:07:07 +0000 Subject: [PATCH 3/3] =?UTF-8?q?=E5=88=A0=E9=99=A4=E6=96=87=E4=BB=B6=20.pup?= =?UTF-8?q?peteerrc.cjs?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .puppeteerrc.cjs | 33 --------------------------------- 1 file changed, 33 deletions(-) delete mode 100644 .puppeteerrc.cjs diff --git a/.puppeteerrc.cjs b/.puppeteerrc.cjs deleted file mode 100644 index 4907718..0000000 --- a/.puppeteerrc.cjs +++ /dev/null @@ -1,33 +0,0 @@ -const os = require("os"); -const { existsSync } = require("fs"); -const arch = os.arch(); -let skipDownload = false; -let executablePath; -//win32 存在 Edge 优先选择 -if (process.platform == "win32") { - if ( - existsSync("C:/Program Files (x86)/Microsoft/Edge/Application/msedge.exe") - ) { - skipDownload = true; - executablePath = - "C:/Program Files (x86)/Microsoft/Edge/Application/msedge.exe"; - } -} else if (process.platform == "linux") { - //如果arm64架构跳过下载 - if (arch == "arm64" || arch == "aarch64") { - skipDownload = true; - } - //不管什么架构,如果存在配置则跳过下载,且配置路径 - if (existsSync("/usr/bin/chromium")) { - skipDownload = true; - executablePath = "/usr/bin/chromium"; - } -} - -/** - * @type {import("puppeteer").Configuration} - */ -module.exports = { - skipDownload, - executablePath, -};