@metaphi-ai/hum 0.2.33 → 0.2.35
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.mjs +16 -13
- package/package.json +1 -1
package/dist/cli.mjs
CHANGED
|
@@ -89459,7 +89459,7 @@ var init_install = __esm({
|
|
|
89459
89459
|
"src/install.js"() {
|
|
89460
89460
|
init_define_HUM_CORE_SUBS();
|
|
89461
89461
|
win = process.platform === "win32";
|
|
89462
|
-
MINE = true ? "0.2.
|
|
89462
|
+
MINE = true ? "0.2.35" : "";
|
|
89463
89463
|
npmFix = (version = "") => `npm i -g @metaphi-ai/hum@${version || "latest"} --foreground-scripts`;
|
|
89464
89464
|
NPM_FIX = npmFix("latest");
|
|
89465
89465
|
humHome = (env3 = process.env) => env3.HUM_HOME || path.join(os3.homedir(), ".hum");
|
|
@@ -89805,10 +89805,10 @@ function clientEnv() {
|
|
|
89805
89805
|
platform: process.platform,
|
|
89806
89806
|
arch: process.arch,
|
|
89807
89807
|
terminal: process.env.TERM_PROGRAM || (process.env.WT_SESSION ? "Windows Terminal" : process.env.TERM || ""),
|
|
89808
|
-
tui: true ? "0.2.
|
|
89808
|
+
tui: true ? "0.2.35" : ""
|
|
89809
89809
|
};
|
|
89810
89810
|
}
|
|
89811
|
-
function startFailure(failures, { npm = /^(node|bun)(\.exe)?$/i.test(String(process.execPath).split(/[\\/]/).pop()), platform: platform2 = process.platform, version = true ? "0.2.
|
|
89811
|
+
function startFailure(failures, { npm = /^(node|bun)(\.exe)?$/i.test(String(process.execPath).split(/[\\/]/).pop()), platform: platform2 = process.platform, version = true ? "0.2.35" : "" } = {}) {
|
|
89812
89812
|
const refused = failures.find((f) => f.error && f.error.code !== "ENOENT");
|
|
89813
89813
|
const fix = npm ? npmFix(version) : updateCommand({ kind: "native" }, platform2);
|
|
89814
89814
|
if (!refused) {
|
|
@@ -91323,7 +91323,7 @@ var after = (ms, fn) => {
|
|
|
91323
91323
|
|
|
91324
91324
|
// src/app.jsx
|
|
91325
91325
|
var import_jsx_runtime3 = __toESM(require_jsx_runtime(), 1);
|
|
91326
|
-
var MINE2 = true ? "0.2.
|
|
91326
|
+
var MINE2 = true ? "0.2.35" : "";
|
|
91327
91327
|
var fmtDur = (s) => s < 60 ? `${Math.max(1, Math.round(s))}s` : `${Math.floor(s / 60)}m ${Math.round(s % 60)}s`;
|
|
91328
91328
|
var plural = (n, w) => `${n} ${w}${n === 1 ? "" : "s"}`;
|
|
91329
91329
|
var shortSession = (name) => (name || "").replace(/\.jsonl$/, "");
|
|
@@ -91491,13 +91491,16 @@ var HELP_PAD = Math.max(...COMMANDS.map((c) => c.name.length));
|
|
|
91491
91491
|
var DIFF_TAIL_LINES = 20;
|
|
91492
91492
|
var PATCH_LINES = 200;
|
|
91493
91493
|
var NEEDS_EVERY_MS = 1e4;
|
|
91494
|
-
var
|
|
91494
|
+
var serverLine = (s) => s.state === "connected" ? `connected \xB7 ${s.tools.length} tool${s.tools.length === 1 ? "" : "s"}${s.signed_in ? " \xB7 signed in" : ""}` : s.state;
|
|
91495
91495
|
var serverActions = (s) => [
|
|
91496
91496
|
{ do: "tools", label: "show tools" },
|
|
91497
|
-
|
|
91498
|
-
|
|
91499
|
-
|
|
91497
|
+
...s.state === "waiting for trust" ? [] : [
|
|
91498
|
+
...s.url ? [{ do: "login", label: s.state === "connected" && s.kept ? "sign in again" : "sign in" }] : [],
|
|
91499
|
+
...s.url && s.kept ? [{ do: "logout", label: "sign out" }] : [],
|
|
91500
|
+
{ do: "reconnect", label: "reconnect" }
|
|
91501
|
+
]
|
|
91500
91502
|
];
|
|
91503
|
+
var serverMark = (s) => s.state === "connected" ? /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(Text2, { color: "green", children: "\u2714 " }) : s.state.startsWith("failed") ? /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(Text2, { color: "red", children: "\u2717 " }) : /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(Text2, { color: "yellow", children: "\xB7 " });
|
|
91501
91504
|
var sourceLabel = (source) => ({ deployment: "deployment", config: "config", plugin: "plugin", agent: "agent file", program: "program" })[(source || "config").split(":")[0]] || source;
|
|
91502
91505
|
var ESC_ESC_MS = 800;
|
|
91503
91506
|
var REWIND_ROWS = 8;
|
|
@@ -93326,9 +93329,9 @@ ${r.content}`).join("\n\n") };
|
|
|
93326
93329
|
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(Text2, { dimColor: true, children: ` ${label}` }),
|
|
93327
93330
|
rows2.map((s) => /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(Box2, { flexDirection: "column", paddingLeft: 2, children: [
|
|
93328
93331
|
/* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(Text2, { children: [
|
|
93329
|
-
s
|
|
93332
|
+
serverMark(s),
|
|
93330
93333
|
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(Text2, { bold: true, children: s.name }),
|
|
93331
|
-
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(Text2, { dimColor: true, children:
|
|
93334
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(Text2, { dimColor: true, children: ` \xB7 ${serverLine(s)}${s.state === "connected" && s.instructions ? " \xB7 with instructions" : ""} \xB7 ${s.at}` })
|
|
93332
93335
|
] }),
|
|
93333
93336
|
s.tools.length ? /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(Text2, { dimColor: true, children: ` ${s.tools.join(" \xB7 ")}` }) : null
|
|
93334
93337
|
] }, s.name))
|
|
@@ -93489,7 +93492,7 @@ ${r.content}`).join("\n\n") };
|
|
|
93489
93492
|
return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(Box2, { flexDirection: "column", paddingX: 1, marginTop: 1, children: [
|
|
93490
93493
|
/* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(Text2, { color: ACCENT, bold: true, children: [
|
|
93491
93494
|
s.name,
|
|
93492
|
-
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(Text2, { dimColor: true, children: ` \xB7 ${
|
|
93495
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(Text2, { dimColor: true, children: ` \xB7 ${serverLine(s)} \xB7 ${s.at}` })
|
|
93493
93496
|
] }),
|
|
93494
93497
|
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(Text2, { children: " " }),
|
|
93495
93498
|
acts.map((a, i) => /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(Box2, { children: [
|
|
@@ -93509,7 +93512,7 @@ ${r.content}`).join("\n\n") };
|
|
|
93509
93512
|
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(Text2, { bold: i === picker.index, children: `${i + 1}. ${m.name}`.padEnd(nameW + 4) }),
|
|
93510
93513
|
/* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(Text2, { dimColor: i !== picker.index, children: [
|
|
93511
93514
|
" ",
|
|
93512
|
-
`${sourceLabel(m.source)} \xB7 ${
|
|
93515
|
+
`${sourceLabel(m.source)} \xB7 ${serverLine(m)}`
|
|
93513
93516
|
] })
|
|
93514
93517
|
] }, m.name)),
|
|
93515
93518
|
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(Text2, { children: " " }),
|
|
@@ -93795,7 +93798,7 @@ init_install();
|
|
|
93795
93798
|
await init_theme();
|
|
93796
93799
|
var import_jsx_runtime5 = __toESM(require_jsx_runtime(), 1);
|
|
93797
93800
|
import { spawnSync as spawnSync6 } from "node:child_process";
|
|
93798
|
-
var MINE3 = true ? "0.2.
|
|
93801
|
+
var MINE3 = true ? "0.2.35" : "0.0.0";
|
|
93799
93802
|
var layout = installLayout();
|
|
93800
93803
|
function completeInstall() {
|
|
93801
93804
|
if (layout.kind !== "npm" || !needsInstall(MINE3)) return;
|