@usepowerplant/cli 0.4.40 → 0.4.42

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
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
2
 
3
- !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="256336c3-1d92-58ef-b7c1-e919def1300b")}catch(e){}}();
3
+ !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="14370588-5b0f-5178-90c6-e1dfda28e8e4")}catch(e){}}();
4
4
  const __cliNodeMajor = Number(process.versions.node.split('.')[0]);
5
5
  if (__cliNodeMajor < 20) {
6
6
  console.error(`powerplant needs Node 20 or newer — this is Node ${process.versions.node}.`);
@@ -60,9 +60,10 @@ var HOOK_SPECS = {
60
60
  maxInputBytes: MAX_PROVIDER_INPUT_BYTES,
61
61
  transcriptRecords: {
62
62
  dir: "cursor-transcripts",
63
- record: (input) => {
63
+ record: (input, event) => {
64
64
  const roots = input.workspace_roots;
65
65
  return {
66
+ event,
66
67
  transcriptPath: absolutePathOrNull(input.transcript_path),
67
68
  workspaceRoots: Array.isArray(roots) && roots.length <= 8 && roots.every((root) => absolutePathOrNull(root) !== null) ? roots : [],
68
69
  ...typeof input.model === "string" && input.model.length <= 256 && { model: input.model }
@@ -118,7 +119,7 @@ function recordHookInput(name, bytes, home, now = /* @__PURE__ */ new Date()) {
118
119
  writeTranscriptRecord(
119
120
  path.join(dir, spec.transcriptRecords.dir),
120
121
  sessionId,
121
- { sessionId, ...spec.transcriptRecords.record(parsed.input) }
122
+ { sessionId, ...spec.transcriptRecords.record(parsed.input, parsed.entry.event) }
122
123
  );
123
124
  } catch {
124
125
  }
@@ -183,4 +184,4 @@ if (process.argv[2] === HOOK_SUBCOMMAND) {
183
184
  });
184
185
  }
185
186
 
186
- //# debugId=256336c3-1d92-58ef-b7c1-e919def1300b
187
+ //# debugId=14370588-5b0f-5178-90c6-e1dfda28e8e4