camstack 1.2.210 → 1.2.211

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/cli.js CHANGED
@@ -4,7 +4,7 @@ import {
4
4
  describeHub,
5
5
  findHubs,
6
6
  validateManualHubUrl
7
- } from "./chunk-EMTOU2RA.js";
7
+ } from "./chunk-NAUJQNCX.js";
8
8
  import "./chunk-LMMQX4CK.js";
9
9
 
10
10
  // src/cli.ts
@@ -41,7 +41,7 @@ async function runServe(args) {
41
41
  ...typeof values.data === "string" ? { data: values.data } : {}
42
42
  };
43
43
  Object.assign(process.env, buildServeEnv(opts));
44
- await import("./launcher-FMNINS4U.js");
44
+ await import("./launcher-UXJ4WU3U.js");
45
45
  }
46
46
 
47
47
  // src/commands/agent.ts
@@ -86,7 +86,7 @@ async function runAgent(args) {
86
86
  ...typeof values.port === "string" ? { port: values.port } : {}
87
87
  };
88
88
  Object.assign(process.env, buildAgentEnv(opts));
89
- await import("./launcher-FMNINS4U.js");
89
+ await import("./launcher-UXJ4WU3U.js");
90
90
  }
91
91
 
92
92
  // src/commands/setup.ts
@@ -2502,8 +2502,8 @@ function cmdSkill(args) {
2502
2502
  import { parseArgs as parseArgs9 } from "util";
2503
2503
 
2504
2504
  // src/mcp/toolsets.ts
2505
- var TOOLSET_NAMES = ["setup", "ops", "configure", "develop"];
2506
- var DEFAULT_TOOLSETS = ["setup", "ops", "configure"];
2505
+ var TOOLSET_NAMES = ["setup", "ops", "configure", "support", "develop"];
2506
+ var DEFAULT_TOOLSETS = ["setup", "ops", "configure", "support"];
2507
2507
  function isToolset(value) {
2508
2508
  return TOOLSET_NAMES.some((name) => name === value);
2509
2509
  }
@@ -2561,7 +2561,7 @@ async function runMcp(args, cliVersion) {
2561
2561
  process.exitCode = 1;
2562
2562
  return;
2563
2563
  }
2564
- const { runPublicMcp } = await import("./server-LHBD6ATG.js");
2564
+ const { runPublicMcp } = await import("./server-OYJZ5RCY.js");
2565
2565
  await runPublicMcp({
2566
2566
  cliVersion,
2567
2567
  toolsets: selection.toolsets,
@@ -332175,6 +332175,65 @@ ${recipe.triggers.map((t2, i) => emitTrigger(t2, i)).join("\n\n")}
332175
332175
  warnings: [...conditions?.warnings ?? [], ...actions.warnings]
332176
332176
  };
332177
332177
  }
332178
+ function stampCondition(condition, resolver) {
332179
+ switch (condition.kind) {
332180
+ case "condition": {
332181
+ if (typeof condition.value !== "number" || condition.unit !== void 0) return condition;
332182
+ const quantity = resolver.fieldQuantity(condition.cap, condition.fieldPath);
332183
+ if (quantity === void 0 || unitsForQuantity(quantity).length < 2) return condition;
332184
+ const base = baseUnitForQuantity(quantity);
332185
+ return base === void 0 ? condition : {
332186
+ ...condition,
332187
+ unit: base
332188
+ };
332189
+ }
332190
+ case "not":
332191
+ return {
332192
+ ...condition,
332193
+ child: stampCondition(condition.child, resolver)
332194
+ };
332195
+ case "all":
332196
+ case "any":
332197
+ return {
332198
+ ...condition,
332199
+ children: condition.children.map((child) => stampCondition(child, resolver))
332200
+ };
332201
+ default:
332202
+ return condition;
332203
+ }
332204
+ }
332205
+ function stampAction(action, resolver) {
332206
+ if (action.kind !== "cap" || action.args === void 0) return action;
332207
+ const argUnits = { ...action.argUnits };
332208
+ for (const [arg, value] of Object.entries(action.args)) {
332209
+ if (typeof value !== "number" || argUnits[arg] !== void 0) continue;
332210
+ const meta = resolver.paramMeta(action.cap, action.method, arg);
332211
+ if (meta !== void 0 && unitsForQuantity(meta.quantity).length > 1) argUnits[arg] = meta.unit;
332212
+ }
332213
+ return Object.keys(argUnits).length === 0 ? action : {
332214
+ ...action,
332215
+ argUnits
332216
+ };
332217
+ }
332218
+ function prepareRecipeUnits(recipe, resolver) {
332219
+ const stamped = {
332220
+ ...recipe,
332221
+ ...recipe.conditions === void 0 ? {} : { conditions: stampCondition(recipe.conditions, resolver) },
332222
+ actions: recipe.actions.map((action) => stampAction(action, resolver))
332223
+ };
332224
+ try {
332225
+ return {
332226
+ ok: true,
332227
+ recipe: normalizeRecipeUnits(stamped, resolver).value
332228
+ };
332229
+ } catch (error) {
332230
+ if (error instanceof QuantityUnitError) return {
332231
+ ok: false,
332232
+ error: error.message
332233
+ };
332234
+ throw error;
332235
+ }
332236
+ }
332178
332237
  var AttachmentMediaTypeSchema = zod.z.enum([
332179
332238
  "image",
332180
332239
  "video",
@@ -431973,6 +432032,7 @@ ${recipe.triggers.map((t2, i) => emitTrigger(t2, i)).join("\n\n")}
431973
432032
  exports.poolMemoryThreshold = poolMemoryThreshold;
431974
432033
  exports.powerMeterCapability = powerMeterCapability;
431975
432034
  exports.prepareNotification = prepareNotification;
432035
+ exports.prepareRecipeUnits = prepareRecipeUnits;
431976
432036
  exports.presenceCapability = presenceCapability;
431977
432037
  exports.presetById = presetById;
431978
432038
  exports.pressureSensorCapability = pressureSensorCapability;