svamp-cli 0.2.150 → 0.2.151

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.mjs CHANGED
@@ -375,7 +375,7 @@ async function main() {
375
375
  }), machineId);
376
376
  process.exit(0);
377
377
  } else if (subcommand === "issue" || subcommand === "issues") {
378
- const { issueCommand } = await import('./commands-BnHPl4F4.mjs');
378
+ const { issueCommand } = await import('./commands--9dm2tSB.mjs');
379
379
  await issueCommand(args.slice(1));
380
380
  process.exit(0);
381
381
  } else if (subcommand === "trigger" || subcommand === "triggers" || subcommand === "routine" || subcommand === "routines") {
@@ -394,7 +394,7 @@ async function main() {
394
394
  } else if (!subcommand || subcommand === "start") {
395
395
  await handleInteractiveCommand();
396
396
  } else if (subcommand === "--version" || subcommand === "-v") {
397
- const pkg = await import('./package-D0GLAfqW.mjs').catch(() => ({ default: { version: "unknown" } }));
397
+ const pkg = await import('./package-JMm_HlGt.mjs').catch(() => ({ default: { version: "unknown" } }));
398
398
  console.log(`svamp version: ${pkg.default.version}`);
399
399
  } else {
400
400
  console.error(`Unknown command: ${subcommand}`);
@@ -232,10 +232,17 @@ async function issueCommand(args) {
232
232
  };
233
233
  switch (sub) {
234
234
  case "add": {
235
- const title = positional(rest)[0];
235
+ let title = positional(rest)[0];
236
+ let body = flag(rest, "--body");
236
237
  if (!title) {
237
- console.error('usage: svamp issue add "<title>" [--ready] [--label x] [--verify-cmd "npm test"] [--scope project|session] [--body "\u2026"]');
238
- process.exit(1);
238
+ const src = (body || "").trim();
239
+ if (!src) {
240
+ console.error('usage: svamp issue add "<title or text>" [--ready] [--label x] [--verify-cmd "npm test"] [--scope project|session] [--body "\u2026"]');
241
+ process.exit(1);
242
+ }
243
+ const nl = src.indexOf("\n");
244
+ title = (nl === -1 ? src : src.slice(0, nl)).trim().slice(0, 200);
245
+ body = nl === -1 ? void 0 : src.slice(nl + 1).trim() || void 0;
239
246
  }
240
247
  const labels = rest.filter((a, idx) => rest[idx - 1] === "--label");
241
248
  const scope = flag(rest, "--scope") || (sessionId ? "session" : "project");
@@ -246,7 +253,7 @@ async function issueCommand(args) {
246
253
  labels,
247
254
  verify: buildVerify(rest),
248
255
  session: scope === "session" ? sessionId : null,
249
- body: flag(rest, "--body")
256
+ body
250
257
  });
251
258
  ok(issue, `Created #${issue.id} (${issue.status}): ${issue.title}`);
252
259
  break;
@@ -400,7 +407,8 @@ ${issue.body}`);
400
407
  out([
401
408
  "svamp issue \u2014 the session backlog (folder of .svamp/issues/<id>.md)",
402
409
  "",
403
- ' add "<title>" [--ready] [--label x] [--verify-cmd "cmd"] [--scope project|session] [--body "\u2026"]',
410
+ ' add ["<title>"] [--ready] [--label x] [--verify-cmd "cmd"] [--scope project|session] [--body "\u2026"]',
411
+ " # title optional \u2014 if omitted, the first line of --body becomes the title",
404
412
  " list [--status ready|backlog|in_progress|done|archived|all] [--label x] [--scope \u2026] [--json]",
405
413
  " show <id> [--json]",
406
414
  " ready <id> | start <id> | close <id> | reopen <id> | backlog <id> | archive <id>",
@@ -1,5 +1,5 @@
1
1
  var name = "svamp-cli";
2
- var version = "0.2.150";
2
+ var version = "0.2.151";
3
3
  var description = "Svamp CLI — AI workspace daemon on Hypha Cloud";
4
4
  var author = "Amun AI AB";
5
5
  var license = "SEE LICENSE IN LICENSE";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "svamp-cli",
3
- "version": "0.2.150",
3
+ "version": "0.2.151",
4
4
  "description": "Svamp CLI — AI workspace daemon on Hypha Cloud",
5
5
  "author": "Amun AI AB",
6
6
  "license": "SEE LICENSE IN LICENSE",