fix discord depends (#549)
This commit is contained in:
committed by
GitHub
Unverified
parent
686bc2f235
commit
c86bacd240
@@ -43,6 +43,7 @@
|
||||
"icons": "zx scripts/generate-icons.mjs",
|
||||
"package": "vite build && zx scripts/bundle-openclaw.mjs && zx scripts/bundle-openclaw-plugins.mjs && zx scripts/bundle-preinstalled-skills.mjs",
|
||||
"package:mac": "pnpm run package && electron-builder --mac --publish never",
|
||||
"package:mac:local": "SKIP_PREINSTALLED_SKILLS=1 pnpm run package && electron-builder --mac --publish never",
|
||||
"package:win": "pnpm run package && electron-builder --win --publish never",
|
||||
"package:linux": "pnpm run package && electron-builder --linux --publish never",
|
||||
"release": "pnpm run uv:download && pnpm run package && electron-builder --publish always",
|
||||
|
||||
@@ -133,6 +133,12 @@ queue.push({ nodeModulesDir: openclawVirtualNM, skipPkg: 'openclaw' });
|
||||
const SKIP_PACKAGES = new Set([
|
||||
'typescript',
|
||||
'@playwright/test',
|
||||
// @discordjs/opus is a native .node addon compiled for the system Node.js
|
||||
// ABI. The Gateway runs inside Electron's utilityProcess which has a
|
||||
// different ABI, so the binary fails with "Cannot find native binding".
|
||||
// The package is optional — openclaw gracefully degrades when absent
|
||||
// (only Discord voice features are affected; text chat works fine).
|
||||
'@discordjs/opus',
|
||||
]);
|
||||
const SKIP_SCOPES = ['@cloudflare/', '@types/'];
|
||||
let skippedDevCount = 0;
|
||||
|
||||
@@ -102,6 +102,12 @@ async function fetchSparseRepo(repo, ref, paths, checkoutDir) {
|
||||
}
|
||||
|
||||
echo`Bundling preinstalled skills...`;
|
||||
|
||||
if (process.env.SKIP_PREINSTALLED_SKILLS === '1') {
|
||||
echo`⏭ SKIP_PREINSTALLED_SKILLS=1 set, skipping skills fetch.`;
|
||||
process.exit(0);
|
||||
}
|
||||
|
||||
const manifestSkills = loadManifest();
|
||||
|
||||
rmSync(OUTPUT_ROOT, { recursive: true, force: true });
|
||||
|
||||
Reference in New Issue
Block a user