mirror of
https://github.com/paperclipai/paperclip.git
synced 2026-10-24 18:19:05 +02:00
18 lines
505 B
TypeScript
18 lines
505 B
TypeScript
import { execFile } from "node:child_process";
|
|
import path from "node:path";
|
|
import { promisify } from "node:util";
|
|
|
|
export async function prepareSourceServerDependencies(
|
|
repositoryRoot: string,
|
|
environment: NodeJS.ProcessEnv,
|
|
installed: boolean,
|
|
) {
|
|
if (installed) return;
|
|
await promisify(execFile)(process.execPath, [path.join(repositoryRoot, "scripts/ensure-plugin-build-deps.mjs")], {
|
|
cwd: repositoryRoot,
|
|
env: environment,
|
|
timeout: 120_000,
|
|
maxBuffer: 1024 * 1024,
|
|
});
|
|
}
|