omegon 0.6.26 → 0.6.27

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.
@@ -471,8 +471,9 @@ function restartOmegon(): never {
471
471
  "done",
472
472
  // Extra grace period for fd/terminal release
473
473
  "sleep 0.2",
474
- // Reset terminal to sane cooked state (stty sane is sufficient;
475
- // avoid printf '\\033c' which nukes scrollback history)
474
+ // Pop kitty keyboard protocol and bracketed paste before resetting
475
+ // stty sane only resets line discipline, not terminal protocol state
476
+ "printf '\\033[<u\\033[>4;0m\\033[?2004l' 2>/dev/null",
476
477
  "stty sane 2>/dev/null",
477
478
  // Clean up this script
478
479
  `rm -f "${script}"`,
@@ -483,6 +484,15 @@ function restartOmegon(): never {
483
484
  // Reset terminal to cooked mode BEFORE exiting so the restart script
484
485
  // (and the user) aren't stuck with raw-mode terminal if something goes wrong.
485
486
  try {
487
+ // Pop kitty keyboard protocol and disable bracketed paste BEFORE
488
+ // releasing raw mode — the terminal needs these escape sequences to
489
+ // stop encoding keystrokes in CSI-u format. Without this, the restart
490
+ // script (and any keystrokes during the wait) dump raw kitty sequences.
491
+ process.stdout.write(
492
+ "\x1b[<u" + // Pop kitty keyboard protocol flags
493
+ "\x1b[>4;0m" + // Disable modifyOtherKeys
494
+ "\x1b[?2004l" // Disable bracketed paste
495
+ );
486
496
  if (process.stdin.isTTY && typeof process.stdin.setRawMode === "function") {
487
497
  process.stdin.setRawMode(false);
488
498
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "omegon",
3
- "version": "0.6.26",
3
+ "version": "0.6.27",
4
4
  "description": "Omegon — an opinionated distribution of pi (by Mario Zechner) with extensions for lifecycle management, memory, orchestration, and visualization",
5
5
  "bin": {
6
6
  "omegon": "bin/omegon.mjs",