mirror of
https://github.com/openclaw/openclaw.git
synced 2026-06-22 11:48:11 +00:00
fix(build): ship export session html assets
Align the export-session template asset copy step and build-all cache output with the runtime lookup path so published packages include the HTML export assets at `dist/export-html`. Adds a focused build-all regression assertion for the output path contract. Fixes #90843
This commit is contained in:
@@ -132,7 +132,7 @@ export const BUILD_ALL_STEPS = [
|
||||
"scripts/lib/copy-assets.ts",
|
||||
"src/auto-reply/reply/export-html",
|
||||
],
|
||||
outputs: ["dist/auto-reply/reply/export-html"],
|
||||
outputs: ["dist/export-html"],
|
||||
},
|
||||
},
|
||||
{
|
||||
|
||||
@@ -16,13 +16,7 @@ const exportHtmlSrcDir = path.join(
|
||||
"reply",
|
||||
"export-html",
|
||||
);
|
||||
const exportHtmlDistDir = path.join(
|
||||
context.projectRoot,
|
||||
"dist",
|
||||
"auto-reply",
|
||||
"reply",
|
||||
"export-html",
|
||||
);
|
||||
const exportHtmlDistDir = path.join(context.projectRoot, "dist", "export-html");
|
||||
|
||||
function copyExportHtmlTemplates() {
|
||||
if (!fs.existsSync(exportHtmlSrcDir)) {
|
||||
|
||||
@@ -173,6 +173,12 @@ describe("resolveBuildAllStep", () => {
|
||||
expect(step.cache?.inputs).toEqual(expect.arrayContaining(["npm-shrinkwrap.json"]));
|
||||
expect(step.cache?.outputs).toEqual(expect.arrayContaining(["dist/plugin-sdk/packages"]));
|
||||
});
|
||||
|
||||
it("keeps export-html build output aligned with runtime template lookup", () => {
|
||||
const step = getBuildAllStep("copy-export-html-templates");
|
||||
|
||||
expect(step.cache?.outputs).toEqual(["dist/export-html"]);
|
||||
});
|
||||
});
|
||||
|
||||
describe("resolveBuildAllSteps", () => {
|
||||
|
||||
Reference in New Issue
Block a user