@hachej/boring-ui-cli 0.1.39 → 0.1.40
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/server/cli.js +10 -1
- package/dist/server/modeApps.js +16 -0
- package/package.json +6 -6
package/dist/server/cli.js
CHANGED
|
@@ -39,7 +39,16 @@ async function registerStatic(app, publicDir) {
|
|
|
39
39
|
const { default: fastifyStatic } = await import("@fastify/static");
|
|
40
40
|
await app.register(fastifyStatic, {
|
|
41
41
|
root: publicDir,
|
|
42
|
-
prefix: "/"
|
|
42
|
+
prefix: "/",
|
|
43
|
+
// @fastify/send writes its own Cache-Control after setHeaders runs, so
|
|
44
|
+
// disable it and set the header explicitly for both cases below.
|
|
45
|
+
cacheControl: false,
|
|
46
|
+
setHeaders(res, filePath) {
|
|
47
|
+
res.setHeader(
|
|
48
|
+
"cache-control",
|
|
49
|
+
/[\\/]assets[\\/]/.test(filePath) ? "public, max-age=31536000, immutable" : "public, max-age=0"
|
|
50
|
+
);
|
|
51
|
+
}
|
|
43
52
|
});
|
|
44
53
|
app.setNotFoundHandler(async (req, reply) => {
|
|
45
54
|
if (req.url.startsWith("/api/")) {
|
package/dist/server/modeApps.js
CHANGED
|
@@ -630,6 +630,22 @@ async function createWorkspacesModeApp(opts) {
|
|
|
630
630
|
runtimePluginTrustDescription: RUNTIME_PLUGIN_TRUST_DESCRIPTION,
|
|
631
631
|
runtimePluginDiagnosticsEnabled: true
|
|
632
632
|
}));
|
|
633
|
+
void (async () => {
|
|
634
|
+
await new Promise((resolve2) => setTimeout(resolve2, 250));
|
|
635
|
+
try {
|
|
636
|
+
const byRecency = [...await registry.list()].sort((a, b) => b.updatedAt.localeCompare(a.updatedAt));
|
|
637
|
+
for (const workspace of byRecency) {
|
|
638
|
+
if (!workspace.available) continue;
|
|
639
|
+
try {
|
|
640
|
+
await getLoadedPluginRuntime(workspace);
|
|
641
|
+
} catch (error) {
|
|
642
|
+
app.log.warn({ err: error, workspaceId: workspace.id }, "[cli] workspace plugin prewarm failed");
|
|
643
|
+
}
|
|
644
|
+
}
|
|
645
|
+
} catch (error) {
|
|
646
|
+
app.log.warn({ err: error }, "[cli] workspace plugin prewarm skipped");
|
|
647
|
+
}
|
|
648
|
+
})();
|
|
633
649
|
return app;
|
|
634
650
|
}
|
|
635
651
|
export {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hachej/boring-ui-cli",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.40",
|
|
4
4
|
"description": "Turn an agent into an app",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -19,11 +19,11 @@
|
|
|
19
19
|
"lucide-react": "^1.8.0",
|
|
20
20
|
"typescript": "^5.8.3",
|
|
21
21
|
"vite": "^6.0.0",
|
|
22
|
-
"@hachej/boring-agent": "0.1.
|
|
23
|
-
"@hachej/boring-ui-kit": "0.1.
|
|
24
|
-
"@hachej/boring-ask-user": "0.1.
|
|
25
|
-
"@hachej/boring-
|
|
26
|
-
"@hachej/boring-
|
|
22
|
+
"@hachej/boring-agent": "0.1.40",
|
|
23
|
+
"@hachej/boring-ui-kit": "0.1.40",
|
|
24
|
+
"@hachej/boring-ask-user": "0.1.40",
|
|
25
|
+
"@hachej/boring-ui-plugin-cli": "0.1.40",
|
|
26
|
+
"@hachej/boring-workspace": "0.1.40"
|
|
27
27
|
},
|
|
28
28
|
"devDependencies": {
|
|
29
29
|
"@tailwindcss/vite": "^4.0.0",
|