import fs from "node:fs"; import os from "node:os"; import path from "node:path"; import { resetDiagnosticEventsForTest } from "../infra/diagnostic-events.js"; import { withEnv } from "../test-utils/env.js"; import { clearPluginDiscoveryCache } from "./discovery.js"; import { clearPluginLoaderCache, loadOpenClawPlugins } from "./loader.js"; import { clearPluginManifestRegistryCache } from "./manifest-registry.js"; import { resetPluginRuntimeStateForTest } from "./runtime.js";
export type TempPlugin = { dir: string; file: string; id: string };
export type PluginLoadConfig = NonNullable<Parameters<typeof loadOpenClawPlugins>[0]>["config"];
export type PluginRegistry = ReturnType<typeof loadOpenClawPlugins>;
function chmodSafeDir(dir: string) { if (process.platform === "win32") { return;
}
fs.chmodSync(dir, 0o755);
}
function mkdtempSafe(prefix: string) { const dir = fs.mkdtempSync(prefix);
chmodSafeDir(dir); return dir;
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.