@mutmutco/cli 2.34.0 → 2.35.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.
package/README.md CHANGED
@@ -47,7 +47,7 @@ mmi-cli doctor --json
47
47
  - `mmi-cli issue create` creates typed, prioritized GitHub issues (priority sets the board field, not a label) and queues related-issue discovery. `--parent <ref>` files the new issue as a native GitHub sub-issue of a parent (works cross-repo); `mmi-cli issue link-child <parent> <child>` links two existing issues the same way.
48
48
  - `mmi-cli report` files a friction report on the Hub board with your GitHub identity, deduping against the open `report`-labeled issues (a confident duplicate becomes a +1 comment, not a new issue). No repo-local `.env`, no API key, no copied report script.
49
49
  - `mmi-cli skill-lesson --skill <name>` files a **skill-lesson** on the Hub board when a skill's own instructions misfire — the cross-skill generalization of grind's Retro. GitHub identity, its own `skill-lesson` label + dedup pool (a confident duplicate becomes a +1 comment), and a footer pinning the source checkout + plugin SHA. Advisory: the fix lands via a reviewed PR to the skill in MMI-Hub, never a live edit.
50
- - `mmi-cli pr create` and `pr merge` create PRs and land them with branch/worktree cleanup; `mmi-cli gc` dry-runs cleanup of merged/closed PR branches + stale tracking refs.
50
+ - `mmi-cli pr create`, `pr merge`, and **`pr land`** (train probe → checks-wait → merge --auto #1440) create/land PRs with branch/worktree cleanup; **`mmi-cli ci audit`** / **`ci reconcile`** scan fleet merge-readiness; `mmi-cli gc` dry-runs cleanup of merged/closed PR branches + stale tracking refs.
51
51
  - `mmi-cli board read|claim|show|move|done|backfill-priority` reads and moves GitHub Project work.
52
52
  - `mmi-cli tenant control <owner/repo> <stage> <status|start|stop|restart>` runs bounded dev/rc box control for project-admins through the Hub API; main remains master-only.
53
53
  - `mmi-cli stage`, `stage start`, `stage stop`, `stage run`, and `port-range <repo>` manage the local gitignored stage and its port block; `stage-live` explains that remote rc/live move only via `/rcand` · `/release` · `/hotfix`.
package/dist/index.cjs CHANGED
@@ -60,17 +60,26 @@ var init_client_version = __esm({
60
60
  function setInjectedStdin(payload) {
61
61
  injectedStdin = payload;
62
62
  }
63
+ function stdinHasPipedInput(statFd = () => (0, import_node_fs2.fstatSync)(0)) {
64
+ try {
65
+ const stat = statFd();
66
+ return stat.isFIFO() || stat.isFile();
67
+ } catch {
68
+ return false;
69
+ }
70
+ }
63
71
  async function readStdin() {
64
72
  if (injectedStdin !== void 0) return injectedStdin;
65
- if (process.stdin.isTTY !== false) return "";
73
+ if (!stdinHasPipedInput()) return "";
66
74
  const chunks = [];
67
75
  for await (const chunk of process.stdin) chunks.push(chunk);
68
76
  return Buffer.concat(chunks).toString("utf8");
69
77
  }
70
- var injectedStdin;
78
+ var import_node_fs2, injectedStdin;
71
79
  var init_stdin_inject = __esm({
72
80
  "src/stdin-inject.ts"() {
73
81
  "use strict";
82
+ import_node_fs2 = require("node:fs");
74
83
  }
75
84
  });
76
85
 
@@ -83,7 +92,7 @@ function tokenPath(env = process.env) {
83
92
  }
84
93
  function readDaemonToken(env = process.env) {
85
94
  try {
86
- const t = (0, import_node_fs2.readFileSync)(tokenPath(env), "utf8").trim();
95
+ const t = (0, import_node_fs3.readFileSync)(tokenPath(env), "utf8").trim();
87
96
  return t.length > 0 ? t : void 0;
88
97
  } catch {
89
98
  return void 0;
@@ -124,12 +133,12 @@ function parseLine(line) {
124
133
  return void 0;
125
134
  }
126
135
  }
127
- var import_node_crypto, import_node_fs2, import_node_os, import_node_path2, DEFAULT_IDLE_EXIT_MS, DEFAULT_CONNECT_TIMEOUT_MS, DEFAULT_RESPONSE_TIMEOUT_MS, HOT_VERBS, STDIN_VERBS, encodeLine, MAX_FRAME_LENGTH, LineBuffer;
136
+ var import_node_crypto, import_node_fs3, import_node_os, import_node_path2, DEFAULT_IDLE_EXIT_MS, DEFAULT_CONNECT_TIMEOUT_MS, DEFAULT_RESPONSE_TIMEOUT_MS, HOT_VERBS, STDIN_VERBS, encodeLine, MAX_FRAME_LENGTH, LineBuffer;
128
137
  var init_daemon_protocol = __esm({
129
138
  "src/daemon-protocol.ts"() {
130
139
  "use strict";
131
140
  import_node_crypto = require("node:crypto");
132
- import_node_fs2 = require("node:fs");
141
+ import_node_fs3 = require("node:fs");
133
142
  import_node_os = require("node:os");
134
143
  import_node_path2 = require("node:path");
135
144
  DEFAULT_IDLE_EXIT_MS = 30 * 6e4;
@@ -170,7 +179,7 @@ __export(daemon_client_exports, {
170
179
  function clientStamp() {
171
180
  let mtime = 0;
172
181
  try {
173
- mtime = (0, import_node_fs3.statSync)((0, import_node_path3.join)(__dirname, "index.cjs")).mtimeMs;
182
+ mtime = (0, import_node_fs4.statSync)((0, import_node_path3.join)(__dirname, "index.cjs")).mtimeMs;
174
183
  } catch {
175
184
  }
176
185
  return buildStamp(resolveClientVersion(), mtime);
@@ -264,13 +273,13 @@ async function tryDaemonRun(args, deps = {}) {
264
273
  return { handled: false, stdin };
265
274
  }
266
275
  }
267
- var import_node_net, import_node_child_process, import_node_fs3, import_node_os2, import_node_path3;
276
+ var import_node_net, import_node_child_process, import_node_fs4, import_node_os2, import_node_path3;
268
277
  var init_daemon_client = __esm({
269
278
  "src/daemon-client.ts"() {
270
279
  "use strict";
271
280
  import_node_net = require("node:net");
272
281
  import_node_child_process = require("node:child_process");
273
- import_node_fs3 = require("node:fs");
282
+ import_node_fs4 = require("node:fs");
274
283
  import_node_os2 = require("node:os");
275
284
  import_node_path3 = require("node:path");
276
285
  init_client_version();