@meet-ai/cli 0.0.24 → 0.0.25
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/index.js +23 -13
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -15282,7 +15282,8 @@ var init_schema6 = __esm(() => {
|
|
|
15282
15282
|
exclude: exports_external.string().optional(),
|
|
15283
15283
|
senderType: exports_external.string().optional(),
|
|
15284
15284
|
team: exports_external.string().optional(),
|
|
15285
|
-
inbox: exports_external.string().optional()
|
|
15285
|
+
inbox: exports_external.string().optional(),
|
|
15286
|
+
stdinPane: exports_external.string().optional()
|
|
15286
15287
|
}).refine((data) => !(data.inbox && !data.team), {
|
|
15287
15288
|
message: "--inbox requires --team",
|
|
15288
15289
|
path: ["inbox"]
|
|
@@ -15345,7 +15346,8 @@ var init_inbox_router = __esm(() => {
|
|
|
15345
15346
|
});
|
|
15346
15347
|
|
|
15347
15348
|
// src/commands/listen/usecase.ts
|
|
15348
|
-
|
|
15349
|
+
import { execFileSync } from "node:child_process";
|
|
15350
|
+
function routeToInbox(msg, inboxDir, defaultInboxPath, teamDir, stdinPane, attachmentPaths) {
|
|
15349
15351
|
const entry = {
|
|
15350
15352
|
from: `meet-ai:${msg.sender}`,
|
|
15351
15353
|
text: msg.content,
|
|
@@ -15361,13 +15363,15 @@ function routeToInbox(msg, inboxDir, defaultInboxPath, teamDir, attachmentPaths)
|
|
|
15361
15363
|
for (const target of targets) {
|
|
15362
15364
|
appendToInbox(`${inboxDir}/${target}.json`, entry);
|
|
15363
15365
|
}
|
|
15366
|
+
} else if (stdinPane) {
|
|
15367
|
+
execFileSync("tmux", ["send-keys", "-t", stdinPane, msg.content, "Enter"]);
|
|
15364
15368
|
} else if (defaultInboxPath) {
|
|
15365
15369
|
appendToInbox(defaultInboxPath, entry);
|
|
15366
15370
|
}
|
|
15367
15371
|
}
|
|
15368
15372
|
function listen(client, input) {
|
|
15369
15373
|
const parsed = ListenInput.parse(input);
|
|
15370
|
-
const { roomId, exclude, senderType, team, inbox } = parsed;
|
|
15374
|
+
const { roomId, exclude, senderType, team, inbox, stdinPane } = parsed;
|
|
15371
15375
|
const inboxDir = team ? `${process.env.HOME}/.claude/teams/${team}/inboxes` : null;
|
|
15372
15376
|
const defaultInboxPath = inboxDir && inbox ? `${inboxDir}/${inbox}.json` : null;
|
|
15373
15377
|
const teamDir = team ? `${process.env.HOME}/.claude/teams/${team}` : null;
|
|
@@ -15377,12 +15381,12 @@ function listen(client, input) {
|
|
|
15377
15381
|
const output = paths.length ? { ...msg, attachments: paths } : msg;
|
|
15378
15382
|
console.log(JSON.stringify(output));
|
|
15379
15383
|
if (inboxDir && teamDir)
|
|
15380
|
-
routeToInbox(msg, inboxDir, defaultInboxPath, teamDir, paths);
|
|
15384
|
+
routeToInbox(msg, inboxDir, defaultInboxPath, teamDir, stdinPane, paths);
|
|
15381
15385
|
});
|
|
15382
15386
|
} else {
|
|
15383
15387
|
console.log(JSON.stringify(msg));
|
|
15384
15388
|
if (inboxDir && teamDir)
|
|
15385
|
-
routeToInbox(msg, inboxDir, defaultInboxPath, teamDir);
|
|
15389
|
+
routeToInbox(msg, inboxDir, defaultInboxPath, teamDir, stdinPane);
|
|
15386
15390
|
}
|
|
15387
15391
|
};
|
|
15388
15392
|
const ws = client.listen(roomId, { exclude, senderType, onMessage });
|
|
@@ -15467,6 +15471,11 @@ var init_command6 = __esm(() => {
|
|
|
15467
15471
|
type: "string",
|
|
15468
15472
|
alias: "i",
|
|
15469
15473
|
description: "Inbox name for routing (requires --team)"
|
|
15474
|
+
},
|
|
15475
|
+
"stdin-pane": {
|
|
15476
|
+
type: "string",
|
|
15477
|
+
alias: "s",
|
|
15478
|
+
description: "tmux pane ID to inject non-@mention messages into via send-keys"
|
|
15470
15479
|
}
|
|
15471
15480
|
},
|
|
15472
15481
|
run({ args }) {
|
|
@@ -15477,7 +15486,8 @@ var init_command6 = __esm(() => {
|
|
|
15477
15486
|
exclude: args.exclude,
|
|
15478
15487
|
senderType: args["sender-type"],
|
|
15479
15488
|
team: args.team,
|
|
15480
|
-
inbox: args.inbox
|
|
15489
|
+
inbox: args.inbox,
|
|
15490
|
+
stdinPane: args["stdin-pane"]
|
|
15481
15491
|
});
|
|
15482
15492
|
} catch (error48) {
|
|
15483
15493
|
err(error48 instanceof Error ? error48.message : String(error48));
|
|
@@ -20843,7 +20853,7 @@ var init_wrap_ansi = __esm(() => {
|
|
|
20843
20853
|
|
|
20844
20854
|
// ../../node_modules/.bun/terminal-size@4.0.1/node_modules/terminal-size/index.js
|
|
20845
20855
|
import process4 from "node:process";
|
|
20846
|
-
import { execFileSync } from "node:child_process";
|
|
20856
|
+
import { execFileSync as execFileSync2 } from "node:child_process";
|
|
20847
20857
|
import fs from "node:fs";
|
|
20848
20858
|
import tty from "node:tty";
|
|
20849
20859
|
function terminalSize() {
|
|
@@ -20869,7 +20879,7 @@ function terminalSize() {
|
|
|
20869
20879
|
}
|
|
20870
20880
|
return devTty() ?? tput() ?? resize() ?? fallback;
|
|
20871
20881
|
}
|
|
20872
|
-
var defaultColumns = 80, defaultRows = 24, exec2 = (command, arguments_, { shell, env: env2 } = {}) =>
|
|
20882
|
+
var defaultColumns = 80, defaultRows = 24, exec2 = (command, arguments_, { shell, env: env2 } = {}) => execFileSync2(command, arguments_, {
|
|
20873
20883
|
encoding: "utf8",
|
|
20874
20884
|
stdio: ["ignore", "pipe", "ignore"],
|
|
20875
20885
|
timeout: 500,
|
|
@@ -54628,7 +54638,7 @@ var init_build2 = __esm(async () => {
|
|
|
54628
54638
|
});
|
|
54629
54639
|
|
|
54630
54640
|
// src/lib/tmux-client.ts
|
|
54631
|
-
import { execFileSync as
|
|
54641
|
+
import { execFileSync as execFileSync3, execFile as execFileCb } from "node:child_process";
|
|
54632
54642
|
function validateSessionName(name) {
|
|
54633
54643
|
if (!SESSION_NAME_RE.test(name) || name.length > 256) {
|
|
54634
54644
|
throw new Error(`Invalid tmux session name: ${name}`);
|
|
@@ -54652,7 +54662,7 @@ class TmuxClient {
|
|
|
54652
54662
|
}
|
|
54653
54663
|
checkAvailability() {
|
|
54654
54664
|
try {
|
|
54655
|
-
const result =
|
|
54665
|
+
const result = execFileSync3("tmux", ["-V"], {
|
|
54656
54666
|
encoding: "utf8",
|
|
54657
54667
|
timeout: 5000,
|
|
54658
54668
|
stdio: ["pipe", "pipe", "pipe"]
|
|
@@ -54783,7 +54793,7 @@ class TmuxClient {
|
|
|
54783
54793
|
attachSession(name) {
|
|
54784
54794
|
validateSessionName(name);
|
|
54785
54795
|
try {
|
|
54786
|
-
|
|
54796
|
+
execFileSync3("tmux", ["-L", this.server, "attach", "-t", name], {
|
|
54787
54797
|
stdio: "inherit",
|
|
54788
54798
|
timeout: 0
|
|
54789
54799
|
});
|
|
@@ -54794,7 +54804,7 @@ class TmuxClient {
|
|
|
54794
54804
|
}
|
|
54795
54805
|
exec(args) {
|
|
54796
54806
|
try {
|
|
54797
|
-
const output =
|
|
54807
|
+
const output = execFileSync3("tmux", args, {
|
|
54798
54808
|
encoding: "utf8",
|
|
54799
54809
|
timeout: 5000,
|
|
54800
54810
|
stdio: ["pipe", "pipe", "pipe"]
|
|
@@ -56301,7 +56311,7 @@ init_output();
|
|
|
56301
56311
|
var main = defineCommand({
|
|
56302
56312
|
meta: {
|
|
56303
56313
|
name: "meet-ai",
|
|
56304
|
-
version: "0.0.
|
|
56314
|
+
version: "0.0.25",
|
|
56305
56315
|
description: "CLI for meet-ai chat rooms — create rooms, send messages, and stream via WebSocket"
|
|
56306
56316
|
},
|
|
56307
56317
|
args: {
|