@kaynooo/cli-proc 0.7.1 → 0.7.3

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/ports-cli.js CHANGED
@@ -2,7 +2,7 @@
2
2
  // @bun
3
3
 
4
4
  // src/ports-cli.ts
5
- import process17 from "process";
5
+ import process18 from "process";
6
6
  // ../kit/src/args.ts
7
7
  import process9 from "process";
8
8
  import { parseArgs } from "util";
@@ -431,18 +431,14 @@ var FULL_STOP = /\.$/;
431
431
  function usageLine(usage, colors = paint(process8.stdout)) {
432
432
  return `${colors.bold("Usage:")} ${usage.replace(USAGE_PREFIX, "").replaceAll(OPTIONAL, (part) => colors.dim(part))}`;
433
433
  }
434
- function helpText(usage, options, colors = paint(process8.stdout), { examples = [], replaces, exits = [] } = {}) {
435
- return [usageLine(usage, colors), ...replacesRows(replaces, colors), "", colors.bold("Options:"), ...optionRows(options, colors), ...exitRows(exits, colors), ...exampleRows(examples, colors)].join(`
434
+ function helpText(usage, options, colors = paint(process8.stdout), { examples = [], exits = [] } = {}) {
435
+ return [usageLine(usage, colors), "", colors.bold("Options:"), ...optionRows(options, colors), ...exitRows(exits, colors), ...exampleRows(examples, colors)].join(`
436
436
  `);
437
437
  }
438
438
  function exitRows(exits, colors = paint(process8.stdout)) {
439
439
  if (exits.length === 0)
440
440
  return [];
441
- const width = Math.max(...exits.map(([code]) => String(code).length));
442
- return ["", colors.bold("Exits:"), ...exits.map(([code, meaning]) => ` ${colors.cyan(String(code).padEnd(width))} ${meaning}`)];
443
- }
444
- function replacesRows(replaces, colors = paint(process8.stdout)) {
445
- return replaces === undefined || outputMode() === "agent" ? [] : ["", `${colors.bold("Instead of:")} ${replaces}`];
441
+ return ["", `${colors.bold("Exit codes:")} ${exits.map(([code, meaning]) => `${colors.cyan(String(code))} ${meaning}`).join(", ")}`];
446
442
  }
447
443
  function wantsHelpJson(env = process8.env) {
448
444
  return env.KIT_HELP === "json";
@@ -738,9 +734,33 @@ function nearestOption(message, options, allowNegative) {
738
734
  const meant = closest(word, known.map((flag) => flag.replace(DASHES, "")));
739
735
  return meant === undefined ? undefined : `did you mean ${known.find((flag) => flag.replace(DASHES, "") === meant)}?`;
740
736
  }
737
+ // ../kit/src/argv.ts
738
+ import { readFileSync as readFileSync2, realpathSync } from "fs";
739
+ import { resolve as resolve3 } from "path";
740
+ import process10 from "process";
741
+ function commandLine() {
742
+ try {
743
+ return readFileSync2("/proc/self/cmdline", "utf8").split("\x00").slice(0, -1);
744
+ } catch {
745
+ return;
746
+ }
747
+ }
748
+ function realPath(word) {
749
+ try {
750
+ return realpathSync(resolve3(word));
751
+ } catch {
752
+ return;
753
+ }
754
+ }
755
+ function scriptArgs(argv = process10.argv.slice(2), cmdline = commandLine(), script = process10.argv[1]) {
756
+ const target = script === undefined ? undefined : realPath(script) ?? script;
757
+ const at = cmdline === undefined || target === undefined ? -1 : cmdline.findIndex((word, index) => index > 0 && (resolve3(word) === script || realPath(word) === target));
758
+ const after = at === -1 ? [] : cmdline.slice(at + 1);
759
+ return after[0] === "--" && after.length === argv.length + 1 && argv.every((word, index) => word === after[index + 1]) ? after : argv;
760
+ }
741
761
  // ../kit/src/process.ts
742
762
  import { constants } from "os";
743
- import process10 from "process";
763
+ import process11 from "process";
744
764
  var KILL_GRACE_MS = 2000;
745
765
  function exitCodeOf(code, signal) {
746
766
  if (code !== null)
@@ -760,7 +780,7 @@ async function runCommand(argv, { cwd, env, stdin = "ignore", timeoutMs, signal,
760
780
  return;
761
781
  try {
762
782
  if (grouped)
763
- process10.kill(-proc.pid, killing);
783
+ process11.kill(-proc.pid, killing);
764
784
  else
765
785
  proc.kill(killing);
766
786
  } catch {}
@@ -834,15 +854,15 @@ var ESCAPE_CODE = new RegExp(`${ESC}(?:\\[[\\x30-\\x3F]*[\\x20-\\x2F]*[\\x40-\\x
834
854
  var RESET_STYLE = `${ESC}[0m`;
835
855
  var CLOSE_LINK = `${ESC}]8;;${ESC}\\`;
836
856
  // ../kit/src/cli.ts
837
- import { readFileSync as readFileSync2, realpathSync } from "fs";
857
+ import { readFileSync as readFileSync3, realpathSync as realpathSync2 } from "fs";
838
858
  import { dirname as dirname3, join as join5 } from "path";
839
- import process12 from "process";
859
+ import process13 from "process";
840
860
 
841
861
  // ../kit/src/usage.ts
842
862
  import { appendFileSync, mkdirSync } from "fs";
843
863
  import { homedir as homedir3 } from "os";
844
864
  import { dirname as dirname2, isAbsolute, join as join4 } from "path";
845
- import process11 from "process";
865
+ import process12 from "process";
846
866
 
847
867
  // ../kit/src/logs.ts
848
868
  var DAY_MS = 24 * 60 * 60 * 1000;
@@ -856,14 +876,14 @@ var usageError;
856
876
  function noteUsageError(message) {
857
877
  usageError = message;
858
878
  }
859
- function stateHome(env = process11.env) {
879
+ function stateHome(env = process12.env) {
860
880
  const dir = env.XDG_STATE_HOME;
861
881
  return dir !== undefined && isAbsolute(dir) ? dir : join4(homedir3(), ".local", "state");
862
882
  }
863
- function usagePath(env = process11.env) {
883
+ function usagePath(env = process12.env) {
864
884
  return join4(stateHome(env), CLI_FOLDER, "usage.jsonl");
865
885
  }
866
- function usageRecorded(env = process11.env) {
886
+ function usageRecorded(env = process12.env) {
867
887
  const off = env.KAYNOOO_CLI_NO_USAGE;
868
888
  return env.NODE_ENV !== "test" && (off === undefined || off === "" || off === "0");
869
889
  }
@@ -877,7 +897,7 @@ function usageEntry(bin, command, argv, code, now = new Date) {
877
897
  usageError = undefined;
878
898
  return { at: now.toISOString(), bin, ...command === undefined ? {} : { command }, flags: flagNames(argv), code, ...unknown === undefined ? {} : { unknown } };
879
899
  }
880
- function recordUsage(entry, env = process11.env) {
900
+ function recordUsage(entry, env = process12.env) {
881
901
  if (!usageRecorded(env))
882
902
  return;
883
903
  try {
@@ -954,7 +974,6 @@ async function help2({ path, header, summary: lazySummary, commands, defaultComm
954
974
  header(colors, summary),
955
975
  "",
956
976
  usageLine(`${prefix} ${defaultCommand === undefined ? colors.cyan("<command>") : `[${colors.cyan("<command>")}]`} [options]`, colors),
957
- ...replacesRows(replaces, colors),
958
977
  "",
959
978
  ...await commandRows(commands, colors),
960
979
  ...own.length === 0 ? [] : ["", `${colors.bold(`Options of ${defaultCommand}:`)} ${colors.dim("the command run when none is named")}`, ...optionRows(Object.fromEntries(own), colors)],
@@ -968,8 +987,8 @@ async function help2({ path, header, summary: lazySummary, commands, defaultComm
968
987
  `);
969
988
  }
970
989
  function printError(prefix, message, hint, cause) {
971
- const colors = paint(process12.stderr);
972
- const styled = takesControlCodes(process12.stderr);
990
+ const colors = paint(process13.stderr);
991
+ const styled = takesControlCodes(process13.stderr);
973
992
  const head = styled ? `${colors.red.bold("error")} ${colors.dim(`${prefix}:`)}` : `error: ${prefix}:`;
974
993
  const under = (label, text, tint) => text === undefined ? "" : `
975
994
  ${styled ? tint(label) : `${label}:`} ${text}`;
@@ -1012,11 +1031,11 @@ async function dispatch(level, typed, { version, redact }) {
1012
1031
  }
1013
1032
  }
1014
1033
  if (name === undefined && level.path.length > 1) {
1015
- console.error(await help2(await expand(level, [...level.path.slice(1), ...argv]), process12.stderr));
1034
+ console.error(await help2(await expand(level, [...level.path.slice(1), ...argv]), process13.stderr));
1016
1035
  return 2;
1017
1036
  }
1018
1037
  if (name === undefined || name === "help" || name === "--help" || name === "-h") {
1019
- console.log(await help2(await expand(level, [...level.path.slice(1), ...argv]), process12.stdout));
1038
+ console.log(await help2(await expand(level, [...level.path.slice(1), ...argv]), process13.stdout));
1020
1039
  return 0;
1021
1040
  }
1022
1041
  if (level.path.length === 1 && (name === "--version" || name === "-v")) {
@@ -1072,24 +1091,24 @@ function candidateLine(candidate) {
1072
1091
  }
1073
1092
  function positionalBeingTyped(before, { options, positionals }) {
1074
1093
  const takesValue = (word) => !word.includes("=") && Object.entries(options).some(([name, { short, type }]) => type === "string" && (word === `--${name}` || word === `-${short}`));
1075
- let index = 0;
1094
+ const typed = [];
1076
1095
  let at = 0;
1077
1096
  while (at < before.length) {
1078
1097
  const word = before[at];
1079
1098
  if (word === "--") {
1080
- index += before.length - at - 1;
1099
+ typed.push(...before.slice(at + 1));
1081
1100
  break;
1082
1101
  }
1083
1102
  if (!word.startsWith("-"))
1084
- index++;
1103
+ typed.push(word);
1085
1104
  else if (takesValue(word))
1086
1105
  at++;
1087
1106
  at++;
1088
1107
  }
1089
1108
  const last = positionals.at(-1);
1090
- if (index < positionals.length)
1091
- return positionals[index];
1092
- return last?.replace("]", "").endsWith("...") === true ? last : undefined;
1109
+ if (typed.length < positionals.length)
1110
+ return { name: positionals[typed.length], typed };
1111
+ return { name: last?.replace("]", "").endsWith("...") === true ? last : undefined, typed };
1093
1112
  }
1094
1113
  async function leafCandidates(run, words) {
1095
1114
  const completing = await completingOf(run);
@@ -1097,12 +1116,12 @@ async function leafCandidates(run, words) {
1097
1116
  return Object.entries(completing.options).map(([name, option]) => option.description === undefined ? `--${name}` : `--${name} ${option.description}`);
1098
1117
  const flag = words.at(-2);
1099
1118
  const option = flag?.startsWith("-") === true ? Object.entries(completing.options).find(([name, { short }]) => flag === `--${name}` || flag === `-${short}`)?.[1] : undefined;
1119
+ const { name, typed } = positionalBeingTyped(words.slice(0, -1), completing);
1100
1120
  if (option?.type === "string") {
1101
- const values = option.choices === undefined ? await option.candidates?.() : option.choices;
1121
+ const values = option.choices === undefined ? await option.candidates?.(typed) : option.choices;
1102
1122
  return values === undefined ? [FILES] : values.map(candidateLine);
1103
1123
  }
1104
- const name = positionalBeingTyped(words.slice(0, -1), completing);
1105
- const values = name === undefined ? undefined : await completing.candidates[name]?.();
1124
+ const values = name === undefined ? undefined : await completing.candidates[name]?.(typed);
1106
1125
  return values === undefined ? [FILES] : values.map(candidateLine);
1107
1126
  }
1108
1127
  async function candidates(scope, defaultCommand, words, before = []) {
@@ -1133,9 +1152,13 @@ async function printCandidates(found) {
1133
1152
  return 0;
1134
1153
  }
1135
1154
  function packageVersion(entry = Bun.main) {
1136
- for (let dir = dirname3(realpathSync(entry));; dir = dirname3(dir)) {
1155
+ let resolved = entry;
1156
+ try {
1157
+ resolved = realpathSync2(entry);
1158
+ } catch {}
1159
+ for (let dir = dirname3(resolved);; dir = dirname3(dir)) {
1137
1160
  try {
1138
- const { version } = JSON.parse(readFileSync2(join5(dir, "package.json"), "utf8"));
1161
+ const { version } = JSON.parse(readFileSync3(join5(dir, "package.json"), "utf8"));
1139
1162
  if (typeof version === "string")
1140
1163
  return version;
1141
1164
  } catch {}
@@ -1143,7 +1166,7 @@ function packageVersion(entry = Bun.main) {
1143
1166
  return "0.0.0";
1144
1167
  }
1145
1168
  }
1146
- async function runCli(cli, argv = process12.argv.slice(2)) {
1169
+ async function runCli(cli, argv = scriptArgs()) {
1147
1170
  const version = cli.version ?? packageVersion();
1148
1171
  if (argv[0] === COMPLETE)
1149
1172
  return printCandidates(candidates(scopeOf(cli.commands, cli.extraCommands, cli.aliases), cli.defaultCommand, argv.slice(1)));
@@ -1170,7 +1193,7 @@ function commandPath(scope, argv) {
1170
1193
  }
1171
1194
  return path.length === 0 ? undefined : path.join(" ");
1172
1195
  }
1173
- async function runMain({ name, version, run, redact, usage }, argv = process12.argv.slice(2)) {
1196
+ async function runMain({ name, version, run, redact, usage }, argv = scriptArgs()) {
1174
1197
  if (argv[0] === COMPLETE)
1175
1198
  return printCandidates(leafCandidates(run, argv.slice(1)));
1176
1199
  if (argv.length === 1 && (argv[0] === "--version" || argv[0] === "-v")) {
@@ -1214,7 +1237,7 @@ function parseSize(text, bareUnit = 1) {
1214
1237
  return Math.round(Number(match[1]) * (suffix === "" ? bareUnit : 1024 ** POWERS[suffix]));
1215
1238
  }
1216
1239
  // ../kit/src/watch.ts
1217
- import process13 from "process";
1240
+ import process14 from "process";
1218
1241
  import { format } from "util";
1219
1242
  var CLEAR_SCREEN = "\x1B[H\x1B[2J";
1220
1243
  var DEFAULT_SECONDS = 2;
@@ -1236,7 +1259,7 @@ function withoutWatch(args) {
1236
1259
  }
1237
1260
  return rest;
1238
1261
  }
1239
- async function watching(value, step, stream = process13.stdout, sleep = Bun.sleep, rounds = Number.POSITIVE_INFINITY) {
1262
+ async function watching(value, step, stream = process14.stdout, sleep = Bun.sleep, rounds = Number.POSITIVE_INFINITY) {
1240
1263
  const interval = value === "" ? DEFAULT_SECONDS * 1000 : duration(value, "watch", DEFAULT_SECONDS * 1000);
1241
1264
  if (!takesControlCodes(stream))
1242
1265
  badUsage("--watch redraws the screen, so it needs a terminal");
@@ -1244,12 +1267,12 @@ async function watching(value, step, stream = process13.stdout, sleep = Bun.slee
1244
1267
  for (let round = 0;round < rounds; round++) {
1245
1268
  const held = [];
1246
1269
  const { log, info } = console;
1247
- const write = process13.stdout.write.bind(process13.stdout);
1270
+ const write = process14.stdout.write.bind(process14.stdout);
1248
1271
  const hold = (...parts) => void held.push(`${format(...parts)}
1249
1272
  `);
1250
1273
  console.log = hold;
1251
1274
  console.info = hold;
1252
- process13.stdout.write = (text) => {
1275
+ process14.stdout.write = (text) => {
1253
1276
  held.push(typeof text === "string" ? text : Buffer.from(text).toString());
1254
1277
  return true;
1255
1278
  };
@@ -1258,7 +1281,7 @@ async function watching(value, step, stream = process13.stdout, sleep = Bun.slee
1258
1281
  } finally {
1259
1282
  console.log = log;
1260
1283
  console.info = info;
1261
- process13.stdout.write = write;
1284
+ process14.stdout.write = write;
1262
1285
  }
1263
1286
  stream.write(`${CLEAR_SCREEN}${held.join("")}`);
1264
1287
  await sleep(interval);
@@ -1267,10 +1290,10 @@ async function watching(value, step, stream = process13.stdout, sleep = Bun.slee
1267
1290
  }
1268
1291
  // src/ports.ts
1269
1292
  import { basename as basename2 } from "path";
1270
- import process16 from "process";
1293
+ import process17 from "process";
1271
1294
 
1272
1295
  // ../kit/src/prompt.ts
1273
- import process15 from "process";
1296
+ import process16 from "process";
1274
1297
 
1275
1298
  // ../kit/src/picker/score.ts
1276
1299
  var BOUNDARY_AFTER = new Set([" ", "/", "-", "_", ".", ":", "\\", "(", "[", ",", "\t"]);
@@ -1335,6 +1358,14 @@ function parseKeys(input, paste = { active: false }, ctrls = []) {
1335
1358
  });
1336
1359
  }
1337
1360
 
1361
+ // ../kit/src/redraw.ts
1362
+ var SYNC_START = "\x1B[?2026h";
1363
+ var SYNC_END = "\x1B[?2026l";
1364
+ function overwrite(lines, columns) {
1365
+ return lines.map((line) => textWidth(line) < columns ? `${line}\x1B[K` : `\x1B[2K${line}`).join(`
1366
+ `);
1367
+ }
1368
+
1338
1369
  // ../kit/src/prompt.ts
1339
1370
  var PROMPT_KEYS = new Set(["up", "down", "pageup", "pagedown", "home", "end", "enter", "cancel", "erase"]);
1340
1371
  function readKeys(input, paste = { active: false }) {
@@ -1362,7 +1393,7 @@ function asking(colors, question, typed, keys) {
1362
1393
  function answer(colors, question, state, picked) {
1363
1394
  return state === "enter" ? `${colors.green("\u2713")} ${question} ${colors.cyan(picked)}` : `${colors.red("\u2717")} ${question} ${colors.dim("cancelled")}`;
1364
1395
  }
1365
- async function ask(question, { hint, terminal = process15 }, render, press) {
1396
+ async function ask(question, { hint, terminal = process16 }, render, press) {
1366
1397
  const { stdin, stderr } = terminal;
1367
1398
  if (!isInteractive(terminal))
1368
1399
  fail(`cannot ask "${question}" off a terminal`, 2, hint);
@@ -1372,8 +1403,7 @@ async function ask(question, { hint, terminal = process15 }, render, press) {
1372
1403
  const columns = () => stderr.columns || 80;
1373
1404
  const draw = (state, last = false) => {
1374
1405
  const frame = render(colors, state, { columns: columns(), rows: stderr.rows || 24 });
1375
- stderr.write(`\r\x1B[0J${frame.join(`
1376
- `)}${last || frame.length < 2 ? "" : `\x1B[${frame.length - 1}A`}${last ? "" : "\r"}`);
1406
+ stderr.write(`${SYNC_START}\r${overwrite(frame, columns())}\x1B[0J${last || frame.length < 2 ? "" : `\x1B[${frame.length - 1}A`}${last ? "" : "\r"}${SYNC_END}`);
1377
1407
  current = state;
1378
1408
  };
1379
1409
  const redraw = () => draw(current);
@@ -1808,9 +1838,8 @@ var usage2 = `ports [port]
1808
1838
 
1809
1839
  Lists what listens on this machine, TCP and UDP over IPv4 and IPv6, one row per port with its bound address, the owning process, its command and its working directory. A port Docker publishes is held by docker-proxy, and shows as its compose project and service when docker is installed; the owner of a socket of another user cannot be read and shows as -.
1810
1840
  \`ports <port>\` keeps that port alone and exits 1 when nothing listens on it.
1811
- \`ports <port> --kill\` stops its owner with SIGTERM, and with --force SIGKILL once --grace has passed, after asking on a terminal unless --yes is given. It refuses processes of other users, pid 1, this command and its ancestors, and docker-proxy, for which it names the container to stop instead.
1812
-
1813
- Exits 0 when it listed or stopped, 1 when nothing listens on the given port or the owner could not be stopped, 2 on a usage error.`;
1841
+ \`ports <port> --kill\` stops its owner with SIGTERM, and with --force SIGKILL once --grace has passed, after asking on a terminal unless --yes is given. It refuses processes of other users, pid 1, this command and its ancestors, and docker-proxy, for which it names the container to stop instead.`;
1842
+ var EXITS = [[0, "it listed or stopped"], [1, "nothing listens on the given port or the owner could not be stopped"], [2, "a usage error"]];
1814
1843
  var options = {
1815
1844
  json: jsonOption("[{ port, protocol, addresses, pid, command, cwd, container }]"),
1816
1845
  kill: { type: "boolean", conflicts: ["watch"], description: "stop the owner of the given port" },
@@ -1859,7 +1888,7 @@ function refusal(row, proc, guard) {
1859
1888
  return reason === undefined ? undefined : `pid ${row.pid} is ${reason}`;
1860
1889
  }
1861
1890
  function render(rows) {
1862
- const colors = paint(process16.stdout);
1891
+ const colors = paint(process17.stdout);
1863
1892
  const cells = rows.map((row) => [
1864
1893
  colors.cyan(String(row.port)),
1865
1894
  row.protocol,
@@ -1871,7 +1900,7 @@ function render(rows) {
1871
1900
  return table([["PORT", "PROTO", "ADDRESS", "PID", "COMMAND", "CWD"], ...cells], { header: true });
1872
1901
  }
1873
1902
  async function stop(port, rows, procs, values) {
1874
- const guard = { uid: process16.getuid?.() ?? -1, mine: new Set(ancestry(process16.pid, procs)) };
1903
+ const guard = { uid: process17.getuid?.() ?? -1, mine: new Set(ancestry(process17.pid, procs)) };
1875
1904
  const targets = new Map;
1876
1905
  for (const row of rows) {
1877
1906
  const reason = refusal(row, row.pid === undefined ? undefined : procs.get(row.pid), guard);
@@ -1884,7 +1913,7 @@ async function stop(port, rows, procs, values) {
1884
1913
  return 1;
1885
1914
  const names = [...targets].map(([pid, row]) => `${pid} (${truncate(row.command ?? "", 40)})`).join(", ");
1886
1915
  if (values.yes !== true) {
1887
- if (!process16.stdin.isTTY)
1916
+ if (!process17.stdin.isTTY)
1888
1917
  fail(`stopping ${names} needs a terminal to ask on: pass --yes`, 2);
1889
1918
  if (await confirm(`Stop ${names}?`, { default: false }) !== true)
1890
1919
  return 1;
@@ -1898,6 +1927,7 @@ async function stop(port, rows, procs, values) {
1898
1927
  }
1899
1928
  async function ports(args) {
1900
1929
  const { values, positionals } = parse(args, usage2, options, {
1930
+ exits: EXITS,
1901
1931
  positionals: ["[port]"],
1902
1932
  replaces: "ss -ltnp | grep, lsof -i, fuser -k and lookups of docker-proxy by hand",
1903
1933
  examples: [
@@ -1915,7 +1945,7 @@ async function ports(args) {
1915
1945
  badUsage(`<port> takes a whole number from 1 to 65535, not ${given}`);
1916
1946
  if (values.kill === true && port === undefined)
1917
1947
  badUsage("--kill takes the port to free: ports <port> --kill");
1918
- const [sockets, owners, procs] = await Promise.all([readSockets(), socketOwners(), snapshot("/proc", (uid) => uid === process16.getuid?.())]);
1948
+ const [sockets, owners, procs] = await Promise.all([readSockets(), socketOwners(), snapshot("/proc", (uid) => uid === process17.getuid?.())]);
1919
1949
  const byPid = new Map(procs.map((proc) => [proc.pid, proc]));
1920
1950
  const wanted = sockets.filter((socket) => port === undefined || socket.port === port);
1921
1951
  const needsDocker = wanted.some((socket) => {
@@ -1936,9 +1966,9 @@ async function ports(args) {
1936
1966
  console.log(render(rows));
1937
1967
  const unknown = rows.filter((row) => row.pid === undefined && row.container === undefined).length;
1938
1968
  if (unknown > 0)
1939
- console.error(paint(process16.stderr).dim(`${unknown} ${unknown === 1 ? "port has" : "ports have"} an owner this user cannot read, shown as -`));
1969
+ console.error(paint(process17.stderr).dim(`${unknown} ${unknown === 1 ? "port has" : "ports have"} an owner this user cannot read, shown as -`));
1940
1970
  return 0;
1941
1971
  }
1942
1972
 
1943
1973
  // src/ports-cli.ts
1944
- process17.exitCode = await runMain({ name: "ports", run: ports });
1974
+ process18.exitCode = await runMain({ name: "ports", run: ports });