sticky-note-cli 2.6.0 → 2.6.1

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sticky-note-cli",
3
- "version": "2.6.0",
3
+ "version": "2.6.1",
4
4
  "description": "Human-to-human handoff for AI coding assistants. Git-backed shared memory for Claude Code and Copilot CLI.",
5
5
  "license": "MIT",
6
6
  "bin": {
@@ -11,9 +11,22 @@
11
11
  const crypto = require("crypto");
12
12
  const path = require("path");
13
13
 
14
+ function _isCopilotCli() {
15
+ return process.argv.includes("--copilot-cli") || !!process.env.COPILOT_CLI;
16
+ }
17
+
18
+ function _emit(text) {
19
+ if (text === undefined) text = "";
20
+ if (_isCopilotCli()) {
21
+ process.stdout.write(JSON.stringify({ additionalContext: text }) + "\n");
22
+ } else {
23
+ process.stdout.write(JSON.stringify({ output: text }) + "\n");
24
+ }
25
+ }
26
+
14
27
  function _safeExit() {
15
28
  try {
16
- process.stdout.write(JSON.stringify({ output: "" }) + "\n");
29
+ _emit("");
17
30
  } catch (_) {
18
31
  process.stdout.write('{"output":""}\n');
19
32
  }
@@ -575,7 +588,7 @@ function main() {
575
588
  if (presenceContext) parts.push(presenceContext);
576
589
 
577
590
  const output = parts.join("\n").trim();
578
- process.stdout.write(JSON.stringify({ output }) + "\n");
591
+ _emit(output);
579
592
  }
580
593
 
581
594
  // ── Entry point ───────────────────────────────────────────