The Node content pipeline (agents/) and the astroagent in-site authoring console are a proprietary, CLI-strategy agent system that shouldn't ship in the cloneable SeedProject base. Remove both and all their wiring: - Delete agents/ (pipeline scripts, prompts, admin server, libs) + runtime - Delete astroagent config, app/.astroagent/ skill, DevConsole component; unhook it from BaseLayout.astro and astro.config.mjs preview env logic - Delete api/cli/resources.php (DB->pipeline resource bridge) - Drop agent blocks from configure.mjs, agent runtime rules from .gitignore, topic/audience from site.config.json, agent prompts from new-site.sh - Strip agent sections from AGENTS.md / README.md / api/.memory/foundation.md Kept: api/app/LLM/* (API-key/REST multi-provider layer — distinct from the CLI agents), api/cli/rebuild.php, and the mde_resources schema. Frontend build verified (npm run build → 14 pages). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01DfzaSFv5okUxCCdvq5RXu1
38 lines
1.1 KiB
JavaScript
Executable file
38 lines
1.1 KiB
JavaScript
Executable file
#!/usr/bin/env node
|
|
/**
|
|
* configure.mjs — stamp site.config.json (the single source of identity) into
|
|
* every engine config. Run after editing site.config.json:
|
|
*
|
|
* node scripts/configure.mjs
|
|
*
|
|
* Writes:
|
|
* - app/src/config/site.json (Astro theme reads this)
|
|
*/
|
|
import { readFileSync, writeFileSync, mkdirSync } from "node:fs";
|
|
import { dirname, resolve } from "node:path";
|
|
import { fileURLToPath } from "node:url";
|
|
|
|
const root = resolve(dirname(fileURLToPath(import.meta.url)), "..");
|
|
const read = (p) => JSON.parse(readFileSync(resolve(root, p), "utf8"));
|
|
const write = (p, obj) => {
|
|
const full = resolve(root, p);
|
|
mkdirSync(dirname(full), { recursive: true });
|
|
writeFileSync(full, JSON.stringify(obj, null, 2) + "\n");
|
|
console.log(" wrote", p);
|
|
};
|
|
|
|
const site = read("site.config.json");
|
|
console.log(`Configuring site: ${site.name} <${site.url}>`);
|
|
|
|
// 1) Astro theme
|
|
write("app/src/config/site.json", {
|
|
name: site.name,
|
|
url: site.url,
|
|
description: site.description,
|
|
tagline: site.tagline,
|
|
language: site.language,
|
|
author: site.author,
|
|
social: site.social,
|
|
});
|
|
|
|
console.log("Done. Rebuild the site: (cd app && npm run build)");
|