Refresh SCUM plugin page contract
This commit is contained in:
@@ -306,6 +306,7 @@ const missing = [];
|
||||
const declaredPermissions = Array.isArray(plugin.declaredPermissions) ? plugin.declaredPermissions : [];
|
||||
const bridgeActions = Array.isArray(plugin.bridgeActions) ? plugin.bridgeActions : [];
|
||||
const lifecycleProfiles = plugin.runtimeProfiles?.lifecycleProfiles ?? [];
|
||||
const pageKeys = (plugin.pages ?? []).map((page) => page.key);
|
||||
if (plugin.version !== expectedVersion) {
|
||||
missing.push(`version ${expectedVersion}`);
|
||||
}
|
||||
@@ -321,6 +322,11 @@ if (!lifecycleProfiles.some((profile) => profile.key === "run-local")) {
|
||||
if (!plugin.gameClientBridge?.commands?.length) {
|
||||
missing.push("game client bridge declarations");
|
||||
}
|
||||
for (const pageKey of ["files-config", "players", "squads", "live-map", "gifts"]) {
|
||||
if (!pageKeys.includes(pageKey)) {
|
||||
missing.push(`SCUM page ${pageKey}`);
|
||||
}
|
||||
}
|
||||
if (missing.length > 0) {
|
||||
console.error(`SCUM plugin registration is stale or incomplete: missing ${missing.join(", ")}`);
|
||||
console.error("Run scripts/dev-reset.sh, restart the local debug stack, then rerun scripts/dev-smoke.sh.");
|
||||
@@ -777,7 +783,7 @@ const manifest = {
|
||||
gameClientBridge: localGameClientBridge
|
||||
};
|
||||
fs.writeFileSync(outputPath, JSON.stringify({
|
||||
manifestRef: "artifact://manifests/game.scum/0.1.0",
|
||||
manifestRef: `artifact://manifests/game.scum/${source.version}`,
|
||||
manifest,
|
||||
assetFiles: readAssetFiles(source)
|
||||
}, null, 2));
|
||||
|
||||
Reference in New Issue
Block a user