@vm0/cli 9.126.0 → 9.126.2

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/index.js CHANGED
@@ -65,7 +65,7 @@ import {
65
65
  source_default,
66
66
  volumeConfigSchema,
67
67
  withErrorHandler
68
- } from "./chunk-XRL42LXP.js";
68
+ } from "./chunk-URQ7CYNV.js";
69
69
  import {
70
70
  __toESM,
71
71
  init_esm_shims
@@ -398,7 +398,7 @@ function getConfigPath() {
398
398
  return join(homedir(), ".vm0", "config.json");
399
399
  }
400
400
  var infoCommand = new Command().name("info").description("Display environment and debug information").action(async () => {
401
- console.log(source_default.bold(`VM0 CLI v${"9.126.0"}`));
401
+ console.log(source_default.bold(`VM0 CLI v${"9.126.2"}`));
402
402
  console.log();
403
403
  const config = await loadConfig();
404
404
  const hasEnvToken = !!process.env.VM0_TOKEN;
@@ -4291,7 +4291,7 @@ var composeCommand = new Command().name("compose").description("Create or update
4291
4291
  options.autoUpdate = false;
4292
4292
  }
4293
4293
  if (options.autoUpdate !== false) {
4294
- await startSilentUpgrade("9.126.0");
4294
+ await startSilentUpgrade("9.126.2");
4295
4295
  }
4296
4296
  try {
4297
4297
  let result;
@@ -4381,7 +4381,7 @@ var mainRunCommand = new Command().name("run").description("Run an agent").argum
4381
4381
  withErrorHandler(
4382
4382
  async (identifier, prompt, options) => {
4383
4383
  if (options.autoUpdate !== false) {
4384
- await startSilentUpgrade("9.126.0");
4384
+ await startSilentUpgrade("9.126.2");
4385
4385
  }
4386
4386
  const { name, version } = parseIdentifier(identifier);
4387
4387
  let composeId;
@@ -5948,11 +5948,15 @@ function formatMetric(metric) {
5948
5948
  const diskPercent = (metric.disk_used / metric.disk_total * 100).toFixed(1);
5949
5949
  return `[${metric.ts}] CPU: ${metric.cpu.toFixed(1)}% | Mem: ${formatBytes(metric.mem_used)}/${formatBytes(metric.mem_total)} (${memPercent}%) | Disk: ${formatBytes(metric.disk_used)}/${formatBytes(metric.disk_total)} (${diskPercent}%)`;
5950
5950
  }
5951
+ function formatFirewallTag(entry) {
5952
+ if (!entry.firewall_name) return "";
5953
+ const billable = entry.firewall_billable ? ` ${source_default.yellow("$")}` : "";
5954
+ return ` ${source_default.cyan(`[${entry.firewall_name}${billable}]`)}`;
5955
+ }
5951
5956
  function formatNetworkDeny(entry) {
5952
5957
  const method = entry.method || "???";
5953
5958
  const url = entry.url || entry.host || "unknown";
5954
- const firewall = entry.firewall_name ? ` ${source_default.cyan(`[${entry.firewall_name}]`)}` : "";
5955
- return `[${entry.timestamp}] ${method.padEnd(6)} ${source_default.red.bold("DENY")} ${source_default.dim(url)}${firewall}`;
5959
+ return `[${entry.timestamp}] ${method.padEnd(6)} ${source_default.red.bold("DENY")} ${source_default.dim(url)}${formatFirewallTag(entry)}`;
5956
5960
  }
5957
5961
  function formatAuthInfo(entry) {
5958
5962
  const tags = [];
@@ -5999,9 +6003,8 @@ function formatNetworkRequest(entry) {
5999
6003
  const requestSize = entry.request_size || 0;
6000
6004
  const responseSize = entry.response_size || 0;
6001
6005
  const url = entry.url || entry.host || "unknown";
6002
- const firewall = entry.firewall_name ? ` ${source_default.cyan(`[${entry.firewall_name}]`)}` : "";
6003
6006
  const error = entry.firewall_error ? ` ${source_default.red(entry.firewall_error)}` : "";
6004
- let line = `[${entry.timestamp}] ${method.padEnd(6)} ${statusColor(status)} ${latencyColor(latencyMs + "ms")} ${formatBytes(requestSize)}/${formatBytes(responseSize)} ${source_default.dim(url)}${firewall}${error}${formatAuthInfo(entry)}`;
6007
+ let line = `[${entry.timestamp}] ${method.padEnd(6)} ${statusColor(status)} ${latencyColor(latencyMs + "ms")} ${formatBytes(requestSize)}/${formatBytes(responseSize)} ${source_default.dim(url)}${formatFirewallTag(entry)}${error}${formatAuthInfo(entry)}`;
6005
6008
  line += formatCaptureFields(entry);
6006
6009
  return line;
6007
6010
  }
@@ -6393,13 +6396,13 @@ var upgradeCommand = new Command().name("upgrade").description("Upgrade vm0 CLI
6393
6396
  if (latestVersion === null) {
6394
6397
  throw new Error("Could not check for updates. Please try again later.");
6395
6398
  }
6396
- if (latestVersion === "9.126.0") {
6397
- console.log(source_default.green(`\u2713 Already up to date (${"9.126.0"})`));
6399
+ if (latestVersion === "9.126.2") {
6400
+ console.log(source_default.green(`\u2713 Already up to date (${"9.126.2"})`));
6398
6401
  return;
6399
6402
  }
6400
6403
  console.log(
6401
6404
  source_default.yellow(
6402
- `Current version: ${"9.126.0"} -> Latest version: ${latestVersion}`
6405
+ `Current version: ${"9.126.2"} -> Latest version: ${latestVersion}`
6403
6406
  )
6404
6407
  );
6405
6408
  console.log();
@@ -6426,7 +6429,7 @@ var upgradeCommand = new Command().name("upgrade").description("Upgrade vm0 CLI
6426
6429
  const success = await performUpgrade(packageManager);
6427
6430
  if (success) {
6428
6431
  console.log(
6429
- source_default.green(`\u2713 Upgraded from ${"9.126.0"} to ${latestVersion}`)
6432
+ source_default.green(`\u2713 Upgraded from ${"9.126.2"} to ${latestVersion}`)
6430
6433
  );
6431
6434
  return;
6432
6435
  }
@@ -6493,7 +6496,7 @@ var whoamiCommand = new Command().name("whoami").description("Show current ident
6493
6496
 
6494
6497
  // src/index.ts
6495
6498
  var program = new Command();
6496
- program.name("vm0").description("VM0 CLI - Build and run agents with natural language").version("9.126.0");
6499
+ program.name("vm0").description("VM0 CLI - Build and run agents with natural language").version("9.126.2");
6497
6500
  program.addCommand(authCommand);
6498
6501
  program.addCommand(infoCommand);
6499
6502
  program.addCommand(composeCommand);