From 2648fa52abca3cb67f5a22f603c25750ac3633c8 Mon Sep 17 00:00:00 2001 From: fofolee Date: Sun, 18 Feb 2024 17:07:41 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E6=95=B4=E7=8E=AF=E5=A2=83=E5=8F=98?= =?UTF-8?q?=E9=87=8F=E9=A1=BA=E5=BA=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- plugin/preload.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/plugin/preload.js b/plugin/preload.js index 05a0357..2660025 100644 --- a/plugin/preload.js +++ b/plugin/preload.js @@ -46,7 +46,11 @@ window.multiProcessDetection = () => { // axios.defaults.adapter = require('axios/lib/adapters/http') -if (!utools.isWindows()) process.env.PATH += ':/usr/local/bin:/usr/local/sbin:/opt/homebrew/bin:/opt/homebrew/sbin' +if (!utools.isWindows()) + process.env.PATH = `/usr/local/bin:/usr/local/sbin:${process.env.PATH}`; + +if (utools.isMacOS()) + process.env.PATH = `/opt/homebrew/bin:/opt/homebrew/sbin:${process.env.PATH}`; const shortCodes = [