@ordewell/web 0.14.11 → 0.14.12
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/main.js +18 -1
- package/dist/server/main.js.map +1 -1
- package/package.json +2 -2
package/dist/server/main.js
CHANGED
|
@@ -1825,7 +1825,7 @@ function liveMeta(id, goal, plan) {
|
|
|
1825
1825
|
goal: goal || "(untitled)",
|
|
1826
1826
|
runners: plan.runners,
|
|
1827
1827
|
taskCount: plan.tasks.flatMap((t) => [t, ...t.subtasks || []]).length,
|
|
1828
|
-
status: plan
|
|
1828
|
+
status: core.listedPlanStatus(plan),
|
|
1829
1829
|
createdAt: plan.generatedAt,
|
|
1830
1830
|
updatedAt: plan.lastUpdated
|
|
1831
1831
|
};
|
|
@@ -2302,6 +2302,22 @@ function runnersRoute(pool) {
|
|
|
2302
2302
|
});
|
|
2303
2303
|
return router;
|
|
2304
2304
|
}
|
|
2305
|
+
function skillsRoute() {
|
|
2306
|
+
const router = new hono.Hono();
|
|
2307
|
+
router.get("/", (c) => {
|
|
2308
|
+
try {
|
|
2309
|
+
const workspace = c.req.query("workspace") || process.cwd();
|
|
2310
|
+
core.assertWorkspaceExists(workspace);
|
|
2311
|
+
const skills = core.createSkillsService(workspace, new WebConfig().workspaceRepos).listSkills();
|
|
2312
|
+
return c.json({
|
|
2313
|
+
skills: skills.map((s) => ({ name: s.name, description: s.description, appliesTo: s.appliesTo, userInvocable: s.userInvocable }))
|
|
2314
|
+
});
|
|
2315
|
+
} catch (err) {
|
|
2316
|
+
return failure(c, err, "list skills");
|
|
2317
|
+
}
|
|
2318
|
+
});
|
|
2319
|
+
return router;
|
|
2320
|
+
}
|
|
2305
2321
|
function modelsRoute(pool) {
|
|
2306
2322
|
const router = new hono.Hono();
|
|
2307
2323
|
router.get("/", async (c) => {
|
|
@@ -2862,6 +2878,7 @@ function createApp(pool, admission, reader = core.createWorkspaceReader({ config
|
|
|
2862
2878
|
app.route("/api/plans", mergePreflightRoute(reader));
|
|
2863
2879
|
app.route("/api/plans", plansRoute(pool));
|
|
2864
2880
|
app.route("/api/runners", runnersRoute(pool));
|
|
2881
|
+
app.route("/api/skills", skillsRoute());
|
|
2865
2882
|
app.route("/api/models", modelsRoute(pool));
|
|
2866
2883
|
app.route("/api/settings", settingsRoute(pool));
|
|
2867
2884
|
app.route("/api/workspaces", workspacesRoute(pool));
|