From e303841373148bce075cee4ad3f679e2419bc698 Mon Sep 17 00:00:00 2001 From: paisley <8197966+su8su@users.noreply.github.com> Date: Sat, 28 Feb 2026 15:00:35 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20bundle=20dingtalk=20plugin=20mirror=20c?= =?UTF-8?q?ross=E2=80=91platform=20and=20fix=20windows=20packaging?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- electron/main/ipc-handlers.ts | 14 +++++++++----- scripts/installer.nsh | 12 +++++------- 2 files changed, 14 insertions(+), 12 deletions(-) diff --git a/electron/main/ipc-handlers.ts b/electron/main/ipc-handlers.ts index 2866384ad..29e6c26e1 100644 --- a/electron/main/ipc-handlers.ts +++ b/electron/main/ipc-handlers.ts @@ -618,12 +618,16 @@ function registerOpenClawHandlers(gatewayManager: GatewayManager): void { } const candidateSources = app.isPackaged - ? [join(process.resourcesPath, 'openclaw-plugins', 'dingtalk')] + ? [ + join(process.resourcesPath, 'openclaw-plugins', 'dingtalk'), + join(process.resourcesPath, 'app.asar.unpacked', 'build', 'openclaw-plugins', 'dingtalk'), + join(process.resourcesPath, 'app.asar.unpacked', 'openclaw-plugins', 'dingtalk') + ] : [ - join(app.getAppPath(), 'build', 'openclaw-plugins', 'dingtalk'), - join(process.cwd(), 'build', 'openclaw-plugins', 'dingtalk'), - join(__dirname, '../../build/openclaw-plugins/dingtalk'), - ]; + join(app.getAppPath(), 'build', 'openclaw-plugins', 'dingtalk'), + join(process.cwd(), 'build', 'openclaw-plugins', 'dingtalk'), + join(__dirname, '../../build/openclaw-plugins/dingtalk'), + ]; const sourceDir = candidateSources.find((dir) => existsSync(join(dir, 'openclaw.plugin.json'))); if (!sourceDir) { diff --git a/scripts/installer.nsh b/scripts/installer.nsh index c40d76c5b..64280f397 100644 --- a/scripts/installer.nsh +++ b/scripts/installer.nsh @@ -1,13 +1,11 @@ ; ClawX Custom NSIS Installer/Uninstaller Script !macro customInstall - ; Enable Windows long path support for all-user (admin) installs. - ; pnpm virtual store and node_modules paths can exceed the default 260-char - ; MAX_PATH limit on Windows. This registry key enables the modern NTFS - ; long-path behavior on Windows 10 1607+ / Windows 11. - ${If} $MultiUser.InstallMode == "AllUsers" - WriteRegDWORD HKLM "SYSTEM\CurrentControlSet\Control\FileSystem" "LongPathsEnabled" 1 - ${EndIf} + ; Enable Windows long path support (Windows 10 1607+ / Windows 11). + ; pnpm virtual store paths can exceed the default MAX_PATH limit of 260 chars. + ; Writing to HKLM requires admin privileges; on per-user installs without + ; elevation this call silently fails — no crash, just no key written. + WriteRegDWORD HKLM "SYSTEM\CurrentControlSet\Control\FileSystem" "LongPathsEnabled" 1 !macroend !macro customUnInstall