negotium 0.1.34 → 0.1.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/cron.js CHANGED
@@ -3654,7 +3654,7 @@ var init_claude_provider = __esm(async () => {
3654
3654
  });
3655
3655
 
3656
3656
  // ../../packages/core/src/version.ts
3657
- var NEGOTIUM_VERSION = "0.1.34";
3657
+ var NEGOTIUM_VERSION = "0.1.35";
3658
3658
 
3659
3659
  // ../../packages/core/src/agents/codex-native-multi-agent.ts
3660
3660
  import { spawn as spawn3 } from "child_process";
@@ -4010,6 +4010,29 @@ function summarizeTargets(values) {
4010
4010
  return targets[0] ?? "";
4011
4011
  return `${targets[0]} +${targets.length - 1}`;
4012
4012
  }
4013
+ function summarizeSsh(words) {
4014
+ let destination = "";
4015
+ let index = 0;
4016
+ while (index < words.length) {
4017
+ const word = words[index] ?? "";
4018
+ if (word === "--") {
4019
+ destination = words[index + 1] ?? "";
4020
+ index += 2;
4021
+ break;
4022
+ }
4023
+ if (!word.startsWith("-")) {
4024
+ destination = word;
4025
+ index += 1;
4026
+ break;
4027
+ }
4028
+ index += SSH_OPTIONS_WITH_VALUE.has(word) ? 2 : 1;
4029
+ }
4030
+ if (!destination)
4031
+ return "ssh";
4032
+ const remoteCommand = words.slice(index).join(" ");
4033
+ const remoteSummary = remoteCommand ? summarizeShellCommand(remoteCommand) : "";
4034
+ return ["ssh", destination, remoteSummary].filter(Boolean).join(" \xB7 ");
4035
+ }
4013
4036
  function summarizeShellPart(value) {
4014
4037
  const words = shellWords(value).filter((word) => !/^\d*>/.test(word));
4015
4038
  while (words[0] === "sudo")
@@ -4029,6 +4052,8 @@ function summarizeShellPart(value) {
4029
4052
  if (executable === "command" && words[0] === "-v") {
4030
4053
  return words[1] ? `find ${commandName(words[1])}` : "find command";
4031
4054
  }
4055
+ if (executable === "ssh")
4056
+ return summarizeSsh(words);
4032
4057
  if (executable === "git") {
4033
4058
  while (words[0]?.startsWith("-")) {
4034
4059
  const option = words.shift();
@@ -4327,8 +4352,31 @@ function formatToolUse(name, input) {
4327
4352
  }
4328
4353
  return displayName;
4329
4354
  }
4330
- var TOOL_SUMMARY_MAX_CHARS = 90, TOOL_SUMMARY_HEAD_CHARS = 52, TOOL_SUMMARY_TAIL_CHARS = 28, TOOL_DIFF_MAX_CHARS = 4000, TOOL_DIFF_SOURCE_MAX_BYTES = 2000000, SHELL_SUMMARY_MAX_PARTS = 3, SUMMARY_KEYS;
4355
+ var TOOL_SUMMARY_MAX_CHARS = 90, TOOL_SUMMARY_HEAD_CHARS = 52, TOOL_SUMMARY_TAIL_CHARS = 28, TOOL_DIFF_MAX_CHARS = 4000, TOOL_DIFF_SOURCE_MAX_BYTES = 2000000, SHELL_SUMMARY_MAX_PARTS = 3, SSH_OPTIONS_WITH_VALUE, SUMMARY_KEYS;
4331
4356
  var init_tool_format = __esm(() => {
4357
+ SSH_OPTIONS_WITH_VALUE = new Set([
4358
+ "-B",
4359
+ "-b",
4360
+ "-c",
4361
+ "-D",
4362
+ "-E",
4363
+ "-e",
4364
+ "-F",
4365
+ "-I",
4366
+ "-i",
4367
+ "-J",
4368
+ "-L",
4369
+ "-l",
4370
+ "-m",
4371
+ "-O",
4372
+ "-o",
4373
+ "-p",
4374
+ "-Q",
4375
+ "-R",
4376
+ "-S",
4377
+ "-W",
4378
+ "-w"
4379
+ ]);
4332
4380
  SUMMARY_KEYS = [
4333
4381
  "command",
4334
4382
  "cmd",
@@ -14953,4 +15001,4 @@ export {
14953
15001
  CRON_CONTEXT_RETAIN_TURNS
14954
15002
  };
14955
15003
 
14956
- //# debugId=3FC11D5B495DA24764756E2164756E21
15004
+ //# debugId=C17E85F0D71C450364756E2164756E21