Files
spark/rust/build_wasm.js
Diego Marcos 3332f609a9 Initial commit
2025-05-24 00:14:53 -07:00

19 lines
492 B
JavaScript

const { execSync } = await import("node:child_process");
const { platform } = await import("node:os");
const isWindows = platform() === "win32";
try {
if (isWindows) {
const output = execSync(
"powershell.exe -ExecutionPolicy Bypass -File ./rust/build_rust_wasm.ps1",
{ stdio: "inherit" },
);
} else {
execSync("rust/build_rust_wasm.sh", { stdio: "inherit" });
}
} catch (err) {
console.error("Failed to build RUST WASM:", err.message);
process.exit(1);
}