numux 1.11.1 → 1.12.0

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.
Files changed (2) hide show
  1. package/dist/numux.js +32 -14
  2. package/package.json +1 -1
package/dist/numux.js CHANGED
@@ -22,7 +22,7 @@ var __commonJS = (cb, mod) => () => (mod || cb((mod = { exports: {} }).exports,
22
22
  var require_package = __commonJS((exports, module) => {
23
23
  module.exports = {
24
24
  name: "numux",
25
- version: "1.11.1",
25
+ version: "1.12.0",
26
26
  description: "Terminal multiplexer with dependency orchestration",
27
27
  type: "module",
28
28
  license: "MIT",
@@ -1876,7 +1876,7 @@ import { BoxRenderable, createCliRenderer } from "@opentui/core";
1876
1876
  // src/ui/keybindings.ts
1877
1877
  var SHORTCUTS = {
1878
1878
  restartAll: { key: "r", label: "Shift+R", description: "restart all", shift: true },
1879
- copy: { key: "y", label: "Y", description: "copy" },
1879
+ copy: { key: "y", label: "Y/\u2318C", description: "copy" },
1880
1880
  search: { key: "f", label: "F", description: "search" },
1881
1881
  restart: { key: "r", label: "R", description: "restart" },
1882
1882
  stopStart: { key: "s", label: "S", description: "stop/start" },
@@ -1921,7 +1921,8 @@ class Pane {
1921
1921
  rows,
1922
1922
  persistent: true,
1923
1923
  showCursor: interactive,
1924
- trimEnd: true
1924
+ trimEnd: true,
1925
+ flexGrow: 1
1925
1926
  });
1926
1927
  const origOnSelectionChanged = this.terminal.onSelectionChanged.bind(this.terminal);
1927
1928
  this.terminal.onSelectionChanged = (selection) => {
@@ -2464,6 +2465,10 @@ class App {
2464
2465
  });
2465
2466
  this.renderer.keyInput.on("keypress", (key) => {
2466
2467
  log(key);
2468
+ if (key.meta && key.name === "c") {
2469
+ this.copySelection();
2470
+ return;
2471
+ }
2467
2472
  if (key.ctrl && key.name === "c") {
2468
2473
  if (this.searchMode) {
2469
2474
  this.exitSearch();
@@ -2745,6 +2750,7 @@ class PrefixDisplay {
2745
2750
  killOthers;
2746
2751
  timestamps;
2747
2752
  stopping = false;
2753
+ startTime = 0;
2748
2754
  constructor(manager, config, options = {}) {
2749
2755
  this.manager = manager;
2750
2756
  this.logWriter = options.logWriter;
@@ -2777,6 +2783,7 @@ class PrefixDisplay {
2777
2783
  `);
2778
2784
  this.shutdown();
2779
2785
  });
2786
+ this.startTime = Date.now();
2780
2787
  const cols = process.stdout.columns || 80;
2781
2788
  const rows = process.stdout.rows || 24;
2782
2789
  await this.manager.startAll(cols, rows);
@@ -2806,17 +2813,7 @@ class PrefixDisplay {
2806
2813
  this.printLine(name, line);
2807
2814
  }
2808
2815
  }
2809
- handleStatus(name, status) {
2810
- if (status === "ready" || status === "failed" || status === "finished" || status === "stopped" || status === "skipped") {
2811
- if (this.noColor) {
2812
- this.printLine(name, `\u2192 ${status}`);
2813
- } else {
2814
- const ansi = STATUS_ANSI[status];
2815
- const statusText = ansi ? `${ansi}${status}${RESET}` : status;
2816
- this.printLine(name, `${DIM}\u2192 ${statusText}${DIM}${RESET}`);
2817
- }
2818
- }
2819
- }
2816
+ handleStatus(_name, _status) {}
2820
2817
  formatTimestamp() {
2821
2818
  const now = new Date;
2822
2819
  const h = String(now.getHours()).padStart(2, "0");
@@ -2870,6 +2867,17 @@ class PrefixDisplay {
2870
2867
  process.exit(code === 0 ? 0 : 1);
2871
2868
  });
2872
2869
  }
2870
+ formatElapsed() {
2871
+ const ms = Date.now() - this.startTime;
2872
+ if (ms < 1000)
2873
+ return `${ms}ms`;
2874
+ const s = ms / 1000;
2875
+ if (s < 60)
2876
+ return `${s.toFixed(1)}s`;
2877
+ const m = Math.floor(s / 60);
2878
+ const rem = s % 60;
2879
+ return `${m}m ${rem.toFixed(0)}s`;
2880
+ }
2873
2881
  printSummary() {
2874
2882
  const states = this.manager.getAllStates();
2875
2883
  const namePad = Math.max(...states.map((s) => s.name.length));
@@ -2888,6 +2896,16 @@ class PrefixDisplay {
2888
2896
  `);
2889
2897
  }
2890
2898
  }
2899
+ const elapsed = this.formatElapsed();
2900
+ if (this.noColor) {
2901
+ process.stdout.write(`
2902
+ Done in ${elapsed}
2903
+ `);
2904
+ } else {
2905
+ process.stdout.write(`
2906
+ ${DIM}Done in ${elapsed}${RESET}
2907
+ `);
2908
+ }
2891
2909
  }
2892
2910
  async shutdown() {
2893
2911
  if (this.stopping)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "numux",
3
- "version": "1.11.1",
3
+ "version": "1.12.0",
4
4
  "description": "Terminal multiplexer with dependency orchestration",
5
5
  "type": "module",
6
6
  "license": "MIT",