@odla-ai/cli 0.46.0 → 0.46.2

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/bin.cjs CHANGED
@@ -1775,7 +1775,7 @@ var init_surface = __esm({
1775
1775
  },
1776
1776
  pm: {
1777
1777
  ...PM_ENTITIES,
1778
- project: { list: {}, add: {}, create: {}, use: {} },
1778
+ project: { list: {}, add: {}, create: {}, use: {}, set: {} },
1779
1779
  handoff: {},
1780
1780
  next: {},
1781
1781
  start: {},
@@ -12057,6 +12057,7 @@ Usage:
12057
12057
  odla-ai pm project list [--app <product-id>] [--status <s>] [--json]
12058
12058
  odla-ai pm project add --app <product-id> --name <name> [--description <text>] [--json]
12059
12059
  odla-ai pm project use <project-id> [--json] [saved for this app, on this machine]
12060
+ odla-ai pm project set <project-id> [--name <n>|--description <text>|--status <active|completed|archived>] [--mutation-id <id>] [--json]
12060
12061
  odla-ai pm goal list [--app <id>] [--project <id>] [--status <s>] [--q <text>] [--limit <n>] [--offset <n>] [--json]
12061
12062
  odla-ai pm task list [--app <id>] [--column <backlog|ready|doing|review|done>] [--goal <id>] [--assignee <id>] [--q <text>] [--limit <n>] [--offset <n>] [--json]
12062
12063
  odla-ai pm decision list [--app <id>] [--status <s>] [--q <text>] [--limit <n>] [--offset <n>] [--json]
@@ -13941,6 +13942,23 @@ async function pmProjectUse(ctx, id2) {
13941
13942
  writePmProjectContext(ctx.rootDir, { appId: project.appId, projectId: project.id });
13942
13943
  emit2(ctx, project, () => ctx.out.log(`using ${project.appId} / ${project.name} (${project.id}) in this worktree`));
13943
13944
  }
13945
+ async function pmProjectSet(ctx, id2, parsed) {
13946
+ const patch2 = {};
13947
+ for (const key of ["name", "description", "status"]) {
13948
+ const value2 = stringOpt(parsed.options[key]);
13949
+ if (value2 !== void 0) patch2[key] = value2;
13950
+ }
13951
+ if (!Object.keys(patch2).length) {
13952
+ throw new Error("pm project set needs --name, --description, or --status <active|completed|archived>");
13953
+ }
13954
+ const { project } = await pmRequest(
13955
+ ctx,
13956
+ "PATCH",
13957
+ `/project/${encodeURIComponent(id2)}`,
13958
+ { patch: patch2, mutationId: writeMutationId2(parsed) }
13959
+ );
13960
+ emit2(ctx, project, () => ctx.out.log(`project ${project.name} (${project.id}) is ${project.status}`));
13961
+ }
13944
13962
  var init_pm_project_actions = __esm({
13945
13963
  "src/pm-project-actions.ts"() {
13946
13964
  "use strict";
@@ -14019,6 +14037,10 @@ async function pmCommand(parsed, deps = {}) {
14019
14037
  assertArgs(parsed, COMMON_OPTIONS, 4);
14020
14038
  return pmProjectUse(await buildContext2(parsed, deps), requireId2(parsed.positionals[3], action3));
14021
14039
  }
14040
+ if (action3 === "set") {
14041
+ assertArgs(parsed, [...COMMON_OPTIONS, "name", "description", "status", "mutation-id"], 4);
14042
+ return pmProjectSet(await buildContext2(parsed, deps), requireId2(parsed.positionals[3], action3), parsed);
14043
+ }
14022
14044
  rejectWord(["pm", "project"], action3);
14023
14045
  }
14024
14046
  if (word === "next") {