opencode-agent-tmux 1.2.3 → 1.2.4

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.
@@ -316,7 +316,7 @@ function hasTmux() {
316
316
  }
317
317
  async function main() {
318
318
  const args = argv.slice(2);
319
- const isCliCommand = args.length > 0 && (["auth", "config", "plugins", "update", "completion"].includes(args[0]) || ["--version", "-v", "--help", "-h"].includes(args[0]));
319
+ const isCliCommand = args.length > 0 && (["auth", "config", "plugins", "update", "completion", "stats"].includes(args[0]) || ["--version", "-v", "--help", "-h"].includes(args[0]));
320
320
  if (isCliCommand) {
321
321
  const opencodeBin2 = findOpencodeBin();
322
322
  if (!opencodeBin2) {
@@ -325,10 +325,21 @@ async function main() {
325
325
  );
326
326
  exit(1);
327
327
  }
328
- const child = spawn(opencodeBin2, args, {
329
- stdio: "inherit",
328
+ const bypassArgs = [...args];
329
+ if (!args.some((arg) => arg.startsWith("--log-level"))) {
330
+ bypassArgs.push("--log-level", "ERROR");
331
+ }
332
+ const child = spawn(opencodeBin2, bypassArgs, {
333
+ stdio: ["inherit", "inherit", "pipe"],
330
334
  env: process.env
331
335
  });
336
+ child.stderr?.on("data", (data) => {
337
+ const lines = data.toString().split("\n");
338
+ const filtered = lines.filter(
339
+ (line) => !/^INFO\s+.*service=models\.dev.*refreshing/.test(line)
340
+ );
341
+ process.stderr.write(filtered.join("\n"));
342
+ });
332
343
  child.on("close", (code) => {
333
344
  exit(code ?? 0);
334
345
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "opencode-agent-tmux",
3
- "version": "1.2.3",
3
+ "version": "1.2.4",
4
4
  "description": "OpenCode plugin that provides tmux integration for viewing agent execution in real-time",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",