dev-cockpit 0.2.2 → 0.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.
package/dist/index.js CHANGED
@@ -17,9 +17,13 @@ import {
17
17
  } from "./chunk-VN6UILQW.js";
18
18
  import {
19
19
  canonical,
20
+ listMappings,
20
21
  lookupConfig,
21
- manifestPath
22
- } from "./chunk-C4GFJDMG.js";
22
+ manifestPath,
23
+ readManifest,
24
+ removeMapping,
25
+ setMapping
26
+ } from "./chunk-A446TCT5.js";
23
27
  import {
24
28
  __commonJS,
25
29
  __export,
@@ -290,8 +294,8 @@ var require_req = __commonJS({
290
294
  if (req.originalUrl) {
291
295
  _req.url = req.originalUrl;
292
296
  } else {
293
- const path21 = req.path;
294
- _req.url = typeof path21 === "string" ? path21 : req.url ? req.url.path || req.url : void 0;
297
+ const path22 = req.path;
298
+ _req.url = typeof path22 === "string" ? path22 : req.url ? req.url.path || req.url : void 0;
295
299
  }
296
300
  if (req.query) {
297
301
  _req.query = req.query;
@@ -456,14 +460,14 @@ var require_redact = __commonJS({
456
460
  }
457
461
  return obj;
458
462
  }
459
- function parsePath(path21) {
463
+ function parsePath(path22) {
460
464
  const parts = [];
461
465
  let current = "";
462
466
  let inBrackets = false;
463
467
  let inQuotes = false;
464
468
  let quoteChar = "";
465
- for (let i2 = 0; i2 < path21.length; i2++) {
466
- const char = path21[i2];
469
+ for (let i2 = 0; i2 < path22.length; i2++) {
470
+ const char = path22[i2];
467
471
  if (!inBrackets && char === ".") {
468
472
  if (current) {
469
473
  parts.push(current);
@@ -594,10 +598,10 @@ var require_redact = __commonJS({
594
598
  return current;
595
599
  }
596
600
  function redactPaths(obj, paths, censor, remove = false) {
597
- for (const path21 of paths) {
598
- const parts = parsePath(path21);
601
+ for (const path22 of paths) {
602
+ const parts = parsePath(path22);
599
603
  if (parts.includes("*")) {
600
- redactWildcardPath(obj, parts, censor, path21, remove);
604
+ redactWildcardPath(obj, parts, censor, path22, remove);
601
605
  } else {
602
606
  if (remove) {
603
607
  removeKey(obj, parts);
@@ -682,8 +686,8 @@ var require_redact = __commonJS({
682
686
  }
683
687
  } else {
684
688
  if (afterWildcard.includes("*")) {
685
- const wrappedCensor = typeof censor === "function" ? (value, path21) => {
686
- const fullPath = [...pathArray.slice(0, pathLength), ...path21];
689
+ const wrappedCensor = typeof censor === "function" ? (value, path22) => {
690
+ const fullPath = [...pathArray.slice(0, pathLength), ...path22];
687
691
  return censor(value, fullPath);
688
692
  } : censor;
689
693
  redactWildcardPath(current, afterWildcard, wrappedCensor, originalPath, remove);
@@ -718,8 +722,8 @@ var require_redact = __commonJS({
718
722
  return null;
719
723
  }
720
724
  const pathStructure = /* @__PURE__ */ new Map();
721
- for (const path21 of pathsToClone) {
722
- const parts = parsePath(path21);
725
+ for (const path22 of pathsToClone) {
726
+ const parts = parsePath(path22);
723
727
  let current = pathStructure;
724
728
  for (let i2 = 0; i2 < parts.length; i2++) {
725
729
  const part = parts[i2];
@@ -771,24 +775,24 @@ var require_redact = __commonJS({
771
775
  }
772
776
  return cloneSelectively(obj, pathStructure);
773
777
  }
774
- function validatePath(path21) {
775
- if (typeof path21 !== "string") {
778
+ function validatePath(path22) {
779
+ if (typeof path22 !== "string") {
776
780
  throw new Error("Paths must be (non-empty) strings");
777
781
  }
778
- if (path21 === "") {
782
+ if (path22 === "") {
779
783
  throw new Error("Invalid redaction path ()");
780
784
  }
781
- if (path21.includes("..")) {
782
- throw new Error(`Invalid redaction path (${path21})`);
785
+ if (path22.includes("..")) {
786
+ throw new Error(`Invalid redaction path (${path22})`);
783
787
  }
784
- if (path21.includes(",")) {
785
- throw new Error(`Invalid redaction path (${path21})`);
788
+ if (path22.includes(",")) {
789
+ throw new Error(`Invalid redaction path (${path22})`);
786
790
  }
787
791
  let bracketCount = 0;
788
792
  let inQuotes = false;
789
793
  let quoteChar = "";
790
- for (let i2 = 0; i2 < path21.length; i2++) {
791
- const char = path21[i2];
794
+ for (let i2 = 0; i2 < path22.length; i2++) {
795
+ const char = path22[i2];
792
796
  if ((char === '"' || char === "'") && bracketCount > 0) {
793
797
  if (!inQuotes) {
794
798
  inQuotes = true;
@@ -802,20 +806,20 @@ var require_redact = __commonJS({
802
806
  } else if (char === "]" && !inQuotes) {
803
807
  bracketCount--;
804
808
  if (bracketCount < 0) {
805
- throw new Error(`Invalid redaction path (${path21})`);
809
+ throw new Error(`Invalid redaction path (${path22})`);
806
810
  }
807
811
  }
808
812
  }
809
813
  if (bracketCount !== 0) {
810
- throw new Error(`Invalid redaction path (${path21})`);
814
+ throw new Error(`Invalid redaction path (${path22})`);
811
815
  }
812
816
  }
813
817
  function validatePaths(paths) {
814
818
  if (!Array.isArray(paths)) {
815
819
  throw new TypeError("paths must be an array");
816
820
  }
817
- for (const path21 of paths) {
818
- validatePath(path21);
821
+ for (const path22 of paths) {
822
+ validatePath(path22);
819
823
  }
820
824
  }
821
825
  function slowRedact(options2 = {}) {
@@ -983,8 +987,8 @@ var require_redaction = __commonJS({
983
987
  if (shape[k] === null) {
984
988
  o2[k] = (value) => topCensor(value, [k]);
985
989
  } else {
986
- const wrappedCensor = typeof censor === "function" ? (value, path21) => {
987
- return censor(value, [k, ...path21]);
990
+ const wrappedCensor = typeof censor === "function" ? (value, path22) => {
991
+ return censor(value, [k, ...path22]);
988
992
  } : censor;
989
993
  o2[k] = Redact({
990
994
  paths: shape[k],
@@ -1205,7 +1209,7 @@ var require_sonic_boom = __commonJS({
1205
1209
  var fs18 = __require("fs");
1206
1210
  var EventEmitter3 = __require("events");
1207
1211
  var inherits = __require("util").inherits;
1208
- var path21 = __require("path");
1212
+ var path22 = __require("path");
1209
1213
  var sleep = require_atomic_sleep();
1210
1214
  var assert = __require("assert");
1211
1215
  var BUSY_WRITE_TIMEOUT = 100;
@@ -1259,7 +1263,7 @@ var require_sonic_boom = __commonJS({
1259
1263
  const mode = sonic.mode;
1260
1264
  if (sonic.sync) {
1261
1265
  try {
1262
- if (sonic.mkdir) fs18.mkdirSync(path21.dirname(file), { recursive: true });
1266
+ if (sonic.mkdir) fs18.mkdirSync(path22.dirname(file), { recursive: true });
1263
1267
  const fd = fs18.openSync(file, flags, mode);
1264
1268
  fileOpened(null, fd);
1265
1269
  } catch (err) {
@@ -1267,7 +1271,7 @@ var require_sonic_boom = __commonJS({
1267
1271
  throw err;
1268
1272
  }
1269
1273
  } else if (sonic.mkdir) {
1270
- fs18.mkdir(path21.dirname(file), { recursive: true }, (err) => {
1274
+ fs18.mkdir(path22.dirname(file), { recursive: true }, (err) => {
1271
1275
  if (err) return fileOpened(err);
1272
1276
  fs18.open(file, flags, mode, fileOpened);
1273
1277
  });
@@ -4338,7 +4342,7 @@ var require_windows = __commonJS({
4338
4342
  module.exports = isexe;
4339
4343
  isexe.sync = sync;
4340
4344
  var fs18 = __require("fs");
4341
- function checkPathExt(path21, options2) {
4345
+ function checkPathExt(path22, options2) {
4342
4346
  var pathext = options2.pathExt !== void 0 ? options2.pathExt : process.env.PATHEXT;
4343
4347
  if (!pathext) {
4344
4348
  return true;
@@ -4349,25 +4353,25 @@ var require_windows = __commonJS({
4349
4353
  }
4350
4354
  for (var i2 = 0; i2 < pathext.length; i2++) {
4351
4355
  var p = pathext[i2].toLowerCase();
4352
- if (p && path21.substr(-p.length).toLowerCase() === p) {
4356
+ if (p && path22.substr(-p.length).toLowerCase() === p) {
4353
4357
  return true;
4354
4358
  }
4355
4359
  }
4356
4360
  return false;
4357
4361
  }
4358
- function checkStat(stat4, path21, options2) {
4362
+ function checkStat(stat4, path22, options2) {
4359
4363
  if (!stat4.isSymbolicLink() && !stat4.isFile()) {
4360
4364
  return false;
4361
4365
  }
4362
- return checkPathExt(path21, options2);
4366
+ return checkPathExt(path22, options2);
4363
4367
  }
4364
- function isexe(path21, options2, cb) {
4365
- fs18.stat(path21, function(er, stat4) {
4366
- cb(er, er ? false : checkStat(stat4, path21, options2));
4368
+ function isexe(path22, options2, cb) {
4369
+ fs18.stat(path22, function(er, stat4) {
4370
+ cb(er, er ? false : checkStat(stat4, path22, options2));
4367
4371
  });
4368
4372
  }
4369
- function sync(path21, options2) {
4370
- return checkStat(fs18.statSync(path21), path21, options2);
4373
+ function sync(path22, options2) {
4374
+ return checkStat(fs18.statSync(path22), path22, options2);
4371
4375
  }
4372
4376
  }
4373
4377
  });
@@ -4378,13 +4382,13 @@ var require_mode = __commonJS({
4378
4382
  module.exports = isexe;
4379
4383
  isexe.sync = sync;
4380
4384
  var fs18 = __require("fs");
4381
- function isexe(path21, options2, cb) {
4382
- fs18.stat(path21, function(er, stat4) {
4385
+ function isexe(path22, options2, cb) {
4386
+ fs18.stat(path22, function(er, stat4) {
4383
4387
  cb(er, er ? false : checkStat(stat4, options2));
4384
4388
  });
4385
4389
  }
4386
- function sync(path21, options2) {
4387
- return checkStat(fs18.statSync(path21), options2);
4390
+ function sync(path22, options2) {
4391
+ return checkStat(fs18.statSync(path22), options2);
4388
4392
  }
4389
4393
  function checkStat(stat4, options2) {
4390
4394
  return stat4.isFile() && checkMode(stat4, options2);
@@ -4417,7 +4421,7 @@ var require_isexe = __commonJS({
4417
4421
  }
4418
4422
  module.exports = isexe;
4419
4423
  isexe.sync = sync;
4420
- function isexe(path21, options2, cb) {
4424
+ function isexe(path22, options2, cb) {
4421
4425
  if (typeof options2 === "function") {
4422
4426
  cb = options2;
4423
4427
  options2 = {};
@@ -4427,7 +4431,7 @@ var require_isexe = __commonJS({
4427
4431
  throw new TypeError("callback not provided");
4428
4432
  }
4429
4433
  return new Promise(function(resolve3, reject) {
4430
- isexe(path21, options2 || {}, function(er, is) {
4434
+ isexe(path22, options2 || {}, function(er, is) {
4431
4435
  if (er) {
4432
4436
  reject(er);
4433
4437
  } else {
@@ -4436,7 +4440,7 @@ var require_isexe = __commonJS({
4436
4440
  });
4437
4441
  });
4438
4442
  }
4439
- core(path21, options2 || {}, function(er, is) {
4443
+ core(path22, options2 || {}, function(er, is) {
4440
4444
  if (er) {
4441
4445
  if (er.code === "EACCES" || options2 && options2.ignoreErrors) {
4442
4446
  er = null;
@@ -4446,9 +4450,9 @@ var require_isexe = __commonJS({
4446
4450
  cb(er, is);
4447
4451
  });
4448
4452
  }
4449
- function sync(path21, options2) {
4453
+ function sync(path22, options2) {
4450
4454
  try {
4451
- return core.sync(path21, options2 || {});
4455
+ return core.sync(path22, options2 || {});
4452
4456
  } catch (er) {
4453
4457
  if (options2 && options2.ignoreErrors || er.code === "EACCES") {
4454
4458
  return false;
@@ -4464,7 +4468,7 @@ var require_isexe = __commonJS({
4464
4468
  var require_which = __commonJS({
4465
4469
  "node_modules/which/which.js"(exports, module) {
4466
4470
  var isWindows2 = process.platform === "win32" || process.env.OSTYPE === "cygwin" || process.env.OSTYPE === "msys";
4467
- var path21 = __require("path");
4471
+ var path22 = __require("path");
4468
4472
  var COLON = isWindows2 ? ";" : ":";
4469
4473
  var isexe = require_isexe();
4470
4474
  var getNotFoundError = (cmd) => Object.assign(new Error(`not found: ${cmd}`), { code: "ENOENT" });
@@ -4502,7 +4506,7 @@ var require_which = __commonJS({
4502
4506
  return opt.all && found.length ? resolve3(found) : reject(getNotFoundError(cmd));
4503
4507
  const ppRaw = pathEnv[i2];
4504
4508
  const pathPart = /^".*"$/.test(ppRaw) ? ppRaw.slice(1, -1) : ppRaw;
4505
- const pCmd = path21.join(pathPart, cmd);
4509
+ const pCmd = path22.join(pathPart, cmd);
4506
4510
  const p = !pathPart && /^\.[\\\/]/.test(cmd) ? cmd.slice(0, 2) + pCmd : pCmd;
4507
4511
  resolve3(subStep(p, i2, 0));
4508
4512
  });
@@ -4529,7 +4533,7 @@ var require_which = __commonJS({
4529
4533
  for (let i2 = 0; i2 < pathEnv.length; i2++) {
4530
4534
  const ppRaw = pathEnv[i2];
4531
4535
  const pathPart = /^".*"$/.test(ppRaw) ? ppRaw.slice(1, -1) : ppRaw;
4532
- const pCmd = path21.join(pathPart, cmd);
4536
+ const pCmd = path22.join(pathPart, cmd);
4533
4537
  const p = !pathPart && /^\.[\\\/]/.test(cmd) ? cmd.slice(0, 2) + pCmd : pCmd;
4534
4538
  for (let j = 0; j < pathExt.length; j++) {
4535
4539
  const cur = p + pathExt[j];
@@ -4577,7 +4581,7 @@ var require_path_key = __commonJS({
4577
4581
  var require_resolveCommand = __commonJS({
4578
4582
  "node_modules/cross-spawn/lib/util/resolveCommand.js"(exports, module) {
4579
4583
  "use strict";
4580
- var path21 = __require("path");
4584
+ var path22 = __require("path");
4581
4585
  var which = require_which();
4582
4586
  var getPathKey = require_path_key();
4583
4587
  function resolveCommandAttempt(parsed, withoutPathExt) {
@@ -4595,7 +4599,7 @@ var require_resolveCommand = __commonJS({
4595
4599
  try {
4596
4600
  resolved = which.sync(parsed.command, {
4597
4601
  path: env[getPathKey({ env })],
4598
- pathExt: withoutPathExt ? path21.delimiter : void 0
4602
+ pathExt: withoutPathExt ? path22.delimiter : void 0
4599
4603
  });
4600
4604
  } catch (e) {
4601
4605
  } finally {
@@ -4604,7 +4608,7 @@ var require_resolveCommand = __commonJS({
4604
4608
  }
4605
4609
  }
4606
4610
  if (resolved) {
4607
- resolved = path21.resolve(hasCustomCwd ? parsed.options.cwd : "", resolved);
4611
+ resolved = path22.resolve(hasCustomCwd ? parsed.options.cwd : "", resolved);
4608
4612
  }
4609
4613
  return resolved;
4610
4614
  }
@@ -4658,8 +4662,8 @@ var require_shebang_command = __commonJS({
4658
4662
  if (!match) {
4659
4663
  return null;
4660
4664
  }
4661
- const [path21, argument] = match[0].replace(/#! ?/, "").split(" ");
4662
- const binary = path21.split("/").pop();
4665
+ const [path22, argument] = match[0].replace(/#! ?/, "").split(" ");
4666
+ const binary = path22.split("/").pop();
4663
4667
  if (binary === "env") {
4664
4668
  return argument;
4665
4669
  }
@@ -4694,7 +4698,7 @@ var require_readShebang = __commonJS({
4694
4698
  var require_parse = __commonJS({
4695
4699
  "node_modules/cross-spawn/lib/parse.js"(exports, module) {
4696
4700
  "use strict";
4697
- var path21 = __require("path");
4701
+ var path22 = __require("path");
4698
4702
  var resolveCommand = require_resolveCommand();
4699
4703
  var escape3 = require_escape();
4700
4704
  var readShebang = require_readShebang();
@@ -4719,7 +4723,7 @@ var require_parse = __commonJS({
4719
4723
  const needsShell = !isExecutableRegExp.test(commandFile);
4720
4724
  if (parsed.options.forceShell || needsShell) {
4721
4725
  const needsDoubleEscapeMetaChars = isCmdShimRegExp.test(commandFile);
4722
- parsed.command = path21.normalize(parsed.command);
4726
+ parsed.command = path22.normalize(parsed.command);
4723
4727
  parsed.command = escape3.command(parsed.command);
4724
4728
  parsed.args = parsed.args.map((arg) => escape3.argument(arg, needsDoubleEscapeMetaChars));
4725
4729
  const shellCommand = [parsed.command].concat(parsed.args).join(" ");
@@ -4906,17 +4910,17 @@ var require_visit = __commonJS({
4906
4910
  visit.BREAK = BREAK;
4907
4911
  visit.SKIP = SKIP;
4908
4912
  visit.REMOVE = REMOVE;
4909
- function visit_(key, node, visitor, path21) {
4910
- const ctrl = callVisitor(key, node, visitor, path21);
4913
+ function visit_(key, node, visitor, path22) {
4914
+ const ctrl = callVisitor(key, node, visitor, path22);
4911
4915
  if (identity4.isNode(ctrl) || identity4.isPair(ctrl)) {
4912
- replaceNode(key, path21, ctrl);
4913
- return visit_(key, ctrl, visitor, path21);
4916
+ replaceNode(key, path22, ctrl);
4917
+ return visit_(key, ctrl, visitor, path22);
4914
4918
  }
4915
4919
  if (typeof ctrl !== "symbol") {
4916
4920
  if (identity4.isCollection(node)) {
4917
- path21 = Object.freeze(path21.concat(node));
4921
+ path22 = Object.freeze(path22.concat(node));
4918
4922
  for (let i2 = 0; i2 < node.items.length; ++i2) {
4919
- const ci = visit_(i2, node.items[i2], visitor, path21);
4923
+ const ci = visit_(i2, node.items[i2], visitor, path22);
4920
4924
  if (typeof ci === "number")
4921
4925
  i2 = ci - 1;
4922
4926
  else if (ci === BREAK)
@@ -4927,13 +4931,13 @@ var require_visit = __commonJS({
4927
4931
  }
4928
4932
  }
4929
4933
  } else if (identity4.isPair(node)) {
4930
- path21 = Object.freeze(path21.concat(node));
4931
- const ck = visit_("key", node.key, visitor, path21);
4934
+ path22 = Object.freeze(path22.concat(node));
4935
+ const ck = visit_("key", node.key, visitor, path22);
4932
4936
  if (ck === BREAK)
4933
4937
  return BREAK;
4934
4938
  else if (ck === REMOVE)
4935
4939
  node.key = null;
4936
- const cv = visit_("value", node.value, visitor, path21);
4940
+ const cv = visit_("value", node.value, visitor, path22);
4937
4941
  if (cv === BREAK)
4938
4942
  return BREAK;
4939
4943
  else if (cv === REMOVE)
@@ -4954,17 +4958,17 @@ var require_visit = __commonJS({
4954
4958
  visitAsync.BREAK = BREAK;
4955
4959
  visitAsync.SKIP = SKIP;
4956
4960
  visitAsync.REMOVE = REMOVE;
4957
- async function visitAsync_(key, node, visitor, path21) {
4958
- const ctrl = await callVisitor(key, node, visitor, path21);
4961
+ async function visitAsync_(key, node, visitor, path22) {
4962
+ const ctrl = await callVisitor(key, node, visitor, path22);
4959
4963
  if (identity4.isNode(ctrl) || identity4.isPair(ctrl)) {
4960
- replaceNode(key, path21, ctrl);
4961
- return visitAsync_(key, ctrl, visitor, path21);
4964
+ replaceNode(key, path22, ctrl);
4965
+ return visitAsync_(key, ctrl, visitor, path22);
4962
4966
  }
4963
4967
  if (typeof ctrl !== "symbol") {
4964
4968
  if (identity4.isCollection(node)) {
4965
- path21 = Object.freeze(path21.concat(node));
4969
+ path22 = Object.freeze(path22.concat(node));
4966
4970
  for (let i2 = 0; i2 < node.items.length; ++i2) {
4967
- const ci = await visitAsync_(i2, node.items[i2], visitor, path21);
4971
+ const ci = await visitAsync_(i2, node.items[i2], visitor, path22);
4968
4972
  if (typeof ci === "number")
4969
4973
  i2 = ci - 1;
4970
4974
  else if (ci === BREAK)
@@ -4975,13 +4979,13 @@ var require_visit = __commonJS({
4975
4979
  }
4976
4980
  }
4977
4981
  } else if (identity4.isPair(node)) {
4978
- path21 = Object.freeze(path21.concat(node));
4979
- const ck = await visitAsync_("key", node.key, visitor, path21);
4982
+ path22 = Object.freeze(path22.concat(node));
4983
+ const ck = await visitAsync_("key", node.key, visitor, path22);
4980
4984
  if (ck === BREAK)
4981
4985
  return BREAK;
4982
4986
  else if (ck === REMOVE)
4983
4987
  node.key = null;
4984
- const cv = await visitAsync_("value", node.value, visitor, path21);
4988
+ const cv = await visitAsync_("value", node.value, visitor, path22);
4985
4989
  if (cv === BREAK)
4986
4990
  return BREAK;
4987
4991
  else if (cv === REMOVE)
@@ -5008,23 +5012,23 @@ var require_visit = __commonJS({
5008
5012
  }
5009
5013
  return visitor;
5010
5014
  }
5011
- function callVisitor(key, node, visitor, path21) {
5015
+ function callVisitor(key, node, visitor, path22) {
5012
5016
  if (typeof visitor === "function")
5013
- return visitor(key, node, path21);
5017
+ return visitor(key, node, path22);
5014
5018
  if (identity4.isMap(node))
5015
- return visitor.Map?.(key, node, path21);
5019
+ return visitor.Map?.(key, node, path22);
5016
5020
  if (identity4.isSeq(node))
5017
- return visitor.Seq?.(key, node, path21);
5021
+ return visitor.Seq?.(key, node, path22);
5018
5022
  if (identity4.isPair(node))
5019
- return visitor.Pair?.(key, node, path21);
5023
+ return visitor.Pair?.(key, node, path22);
5020
5024
  if (identity4.isScalar(node))
5021
- return visitor.Scalar?.(key, node, path21);
5025
+ return visitor.Scalar?.(key, node, path22);
5022
5026
  if (identity4.isAlias(node))
5023
- return visitor.Alias?.(key, node, path21);
5027
+ return visitor.Alias?.(key, node, path22);
5024
5028
  return void 0;
5025
5029
  }
5026
- function replaceNode(key, path21, node) {
5027
- const parent = path21[path21.length - 1];
5030
+ function replaceNode(key, path22, node) {
5031
+ const parent = path22[path22.length - 1];
5028
5032
  if (identity4.isCollection(parent)) {
5029
5033
  parent.items[key] = node;
5030
5034
  } else if (identity4.isPair(parent)) {
@@ -5634,10 +5638,10 @@ var require_Collection = __commonJS({
5634
5638
  var createNode = require_createNode();
5635
5639
  var identity4 = require_identity();
5636
5640
  var Node = require_Node();
5637
- function collectionFromPath(schema, path21, value) {
5641
+ function collectionFromPath(schema, path22, value) {
5638
5642
  let v = value;
5639
- for (let i2 = path21.length - 1; i2 >= 0; --i2) {
5640
- const k = path21[i2];
5643
+ for (let i2 = path22.length - 1; i2 >= 0; --i2) {
5644
+ const k = path22[i2];
5641
5645
  if (typeof k === "number" && Number.isInteger(k) && k >= 0) {
5642
5646
  const a2 = [];
5643
5647
  a2[k] = v;
@@ -5656,7 +5660,7 @@ var require_Collection = __commonJS({
5656
5660
  sourceObjects: /* @__PURE__ */ new Map()
5657
5661
  });
5658
5662
  }
5659
- var isEmptyPath = (path21) => path21 == null || typeof path21 === "object" && !!path21[Symbol.iterator]().next().done;
5663
+ var isEmptyPath = (path22) => path22 == null || typeof path22 === "object" && !!path22[Symbol.iterator]().next().done;
5660
5664
  var Collection = class extends Node.NodeBase {
5661
5665
  constructor(type, schema) {
5662
5666
  super(type);
@@ -5686,11 +5690,11 @@ var require_Collection = __commonJS({
5686
5690
  * be a Pair instance or a `{ key, value }` object, which may not have a key
5687
5691
  * that already exists in the map.
5688
5692
  */
5689
- addIn(path21, value) {
5690
- if (isEmptyPath(path21))
5693
+ addIn(path22, value) {
5694
+ if (isEmptyPath(path22))
5691
5695
  this.add(value);
5692
5696
  else {
5693
- const [key, ...rest] = path21;
5697
+ const [key, ...rest] = path22;
5694
5698
  const node = this.get(key, true);
5695
5699
  if (identity4.isCollection(node))
5696
5700
  node.addIn(rest, value);
@@ -5704,8 +5708,8 @@ var require_Collection = __commonJS({
5704
5708
  * Removes a value from the collection.
5705
5709
  * @returns `true` if the item was found and removed.
5706
5710
  */
5707
- deleteIn(path21) {
5708
- const [key, ...rest] = path21;
5711
+ deleteIn(path22) {
5712
+ const [key, ...rest] = path22;
5709
5713
  if (rest.length === 0)
5710
5714
  return this.delete(key);
5711
5715
  const node = this.get(key, true);
@@ -5719,8 +5723,8 @@ var require_Collection = __commonJS({
5719
5723
  * scalar values from their surrounding node; to disable set `keepScalar` to
5720
5724
  * `true` (collections are always returned intact).
5721
5725
  */
5722
- getIn(path21, keepScalar) {
5723
- const [key, ...rest] = path21;
5726
+ getIn(path22, keepScalar) {
5727
+ const [key, ...rest] = path22;
5724
5728
  const node = this.get(key, true);
5725
5729
  if (rest.length === 0)
5726
5730
  return !keepScalar && identity4.isScalar(node) ? node.value : node;
@@ -5738,8 +5742,8 @@ var require_Collection = __commonJS({
5738
5742
  /**
5739
5743
  * Checks if the collection includes a value with the key `key`.
5740
5744
  */
5741
- hasIn(path21) {
5742
- const [key, ...rest] = path21;
5745
+ hasIn(path22) {
5746
+ const [key, ...rest] = path22;
5743
5747
  if (rest.length === 0)
5744
5748
  return this.has(key);
5745
5749
  const node = this.get(key, true);
@@ -5749,8 +5753,8 @@ var require_Collection = __commonJS({
5749
5753
  * Sets a value in this collection. For `!!set`, `value` needs to be a
5750
5754
  * boolean to add/remove the item from the set.
5751
5755
  */
5752
- setIn(path21, value) {
5753
- const [key, ...rest] = path21;
5756
+ setIn(path22, value) {
5757
+ const [key, ...rest] = path22;
5754
5758
  if (rest.length === 0) {
5755
5759
  this.set(key, value);
5756
5760
  } else {
@@ -8265,9 +8269,9 @@ var require_Document = __commonJS({
8265
8269
  this.contents.add(value);
8266
8270
  }
8267
8271
  /** Adds a value to the document. */
8268
- addIn(path21, value) {
8272
+ addIn(path22, value) {
8269
8273
  if (assertCollection(this.contents))
8270
- this.contents.addIn(path21, value);
8274
+ this.contents.addIn(path22, value);
8271
8275
  }
8272
8276
  /**
8273
8277
  * Create a new `Alias` node, ensuring that the target `node` has the required anchor.
@@ -8342,14 +8346,14 @@ var require_Document = __commonJS({
8342
8346
  * Removes a value from the document.
8343
8347
  * @returns `true` if the item was found and removed.
8344
8348
  */
8345
- deleteIn(path21) {
8346
- if (Collection.isEmptyPath(path21)) {
8349
+ deleteIn(path22) {
8350
+ if (Collection.isEmptyPath(path22)) {
8347
8351
  if (this.contents == null)
8348
8352
  return false;
8349
8353
  this.contents = null;
8350
8354
  return true;
8351
8355
  }
8352
- return assertCollection(this.contents) ? this.contents.deleteIn(path21) : false;
8356
+ return assertCollection(this.contents) ? this.contents.deleteIn(path22) : false;
8353
8357
  }
8354
8358
  /**
8355
8359
  * Returns item at `key`, or `undefined` if not found. By default unwraps
@@ -8364,10 +8368,10 @@ var require_Document = __commonJS({
8364
8368
  * scalar values from their surrounding node; to disable set `keepScalar` to
8365
8369
  * `true` (collections are always returned intact).
8366
8370
  */
8367
- getIn(path21, keepScalar) {
8368
- if (Collection.isEmptyPath(path21))
8371
+ getIn(path22, keepScalar) {
8372
+ if (Collection.isEmptyPath(path22))
8369
8373
  return !keepScalar && identity4.isScalar(this.contents) ? this.contents.value : this.contents;
8370
- return identity4.isCollection(this.contents) ? this.contents.getIn(path21, keepScalar) : void 0;
8374
+ return identity4.isCollection(this.contents) ? this.contents.getIn(path22, keepScalar) : void 0;
8371
8375
  }
8372
8376
  /**
8373
8377
  * Checks if the document includes a value with the key `key`.
@@ -8378,10 +8382,10 @@ var require_Document = __commonJS({
8378
8382
  /**
8379
8383
  * Checks if the document includes a value at `path`.
8380
8384
  */
8381
- hasIn(path21) {
8382
- if (Collection.isEmptyPath(path21))
8385
+ hasIn(path22) {
8386
+ if (Collection.isEmptyPath(path22))
8383
8387
  return this.contents !== void 0;
8384
- return identity4.isCollection(this.contents) ? this.contents.hasIn(path21) : false;
8388
+ return identity4.isCollection(this.contents) ? this.contents.hasIn(path22) : false;
8385
8389
  }
8386
8390
  /**
8387
8391
  * Sets a value in this document. For `!!set`, `value` needs to be a
@@ -8398,13 +8402,13 @@ var require_Document = __commonJS({
8398
8402
  * Sets a value in this document. For `!!set`, `value` needs to be a
8399
8403
  * boolean to add/remove the item from the set.
8400
8404
  */
8401
- setIn(path21, value) {
8402
- if (Collection.isEmptyPath(path21)) {
8405
+ setIn(path22, value) {
8406
+ if (Collection.isEmptyPath(path22)) {
8403
8407
  this.contents = value;
8404
8408
  } else if (this.contents == null) {
8405
- this.contents = Collection.collectionFromPath(this.schema, Array.from(path21), value);
8409
+ this.contents = Collection.collectionFromPath(this.schema, Array.from(path22), value);
8406
8410
  } else if (assertCollection(this.contents)) {
8407
- this.contents.setIn(path21, value);
8411
+ this.contents.setIn(path22, value);
8408
8412
  }
8409
8413
  }
8410
8414
  /**
@@ -10362,9 +10366,9 @@ var require_cst_visit = __commonJS({
10362
10366
  visit.BREAK = BREAK;
10363
10367
  visit.SKIP = SKIP;
10364
10368
  visit.REMOVE = REMOVE;
10365
- visit.itemAtPath = (cst, path21) => {
10369
+ visit.itemAtPath = (cst, path22) => {
10366
10370
  let item = cst;
10367
- for (const [field, index] of path21) {
10371
+ for (const [field, index] of path22) {
10368
10372
  const tok = item?.[field];
10369
10373
  if (tok && "items" in tok) {
10370
10374
  item = tok.items[index];
@@ -10373,23 +10377,23 @@ var require_cst_visit = __commonJS({
10373
10377
  }
10374
10378
  return item;
10375
10379
  };
10376
- visit.parentCollection = (cst, path21) => {
10377
- const parent = visit.itemAtPath(cst, path21.slice(0, -1));
10378
- const field = path21[path21.length - 1][0];
10380
+ visit.parentCollection = (cst, path22) => {
10381
+ const parent = visit.itemAtPath(cst, path22.slice(0, -1));
10382
+ const field = path22[path22.length - 1][0];
10379
10383
  const coll = parent?.[field];
10380
10384
  if (coll && "items" in coll)
10381
10385
  return coll;
10382
10386
  throw new Error("Parent collection not found");
10383
10387
  };
10384
- function _visit(path21, item, visitor) {
10385
- let ctrl = visitor(item, path21);
10388
+ function _visit(path22, item, visitor) {
10389
+ let ctrl = visitor(item, path22);
10386
10390
  if (typeof ctrl === "symbol")
10387
10391
  return ctrl;
10388
10392
  for (const field of ["key", "value"]) {
10389
10393
  const token = item[field];
10390
10394
  if (token && "items" in token) {
10391
10395
  for (let i2 = 0; i2 < token.items.length; ++i2) {
10392
- const ci = _visit(Object.freeze(path21.concat([[field, i2]])), token.items[i2], visitor);
10396
+ const ci = _visit(Object.freeze(path22.concat([[field, i2]])), token.items[i2], visitor);
10393
10397
  if (typeof ci === "number")
10394
10398
  i2 = ci - 1;
10395
10399
  else if (ci === BREAK)
@@ -10400,10 +10404,10 @@ var require_cst_visit = __commonJS({
10400
10404
  }
10401
10405
  }
10402
10406
  if (typeof ctrl === "function" && field === "key")
10403
- ctrl = ctrl(item, path21);
10407
+ ctrl = ctrl(item, path22);
10404
10408
  }
10405
10409
  }
10406
- return typeof ctrl === "function" ? ctrl(item, path21) : ctrl;
10410
+ return typeof ctrl === "function" ? ctrl(item, path22) : ctrl;
10407
10411
  }
10408
10412
  exports.visit = visit;
10409
10413
  }
@@ -13070,7 +13074,7 @@ var require_command = __commonJS({
13070
13074
  "node_modules/commander/lib/command.js"(exports) {
13071
13075
  var EventEmitter3 = __require("node:events").EventEmitter;
13072
13076
  var childProcess = __require("node:child_process");
13073
- var path21 = __require("node:path");
13077
+ var path22 = __require("node:path");
13074
13078
  var fs18 = __require("node:fs");
13075
13079
  var process10 = __require("node:process");
13076
13080
  var { Argument: Argument2, humanReadableArgName } = require_argument();
@@ -14003,9 +14007,9 @@ Expecting one of '${allowedValues.join("', '")}'`);
14003
14007
  let launchWithNode = false;
14004
14008
  const sourceExt = [".js", ".ts", ".tsx", ".mjs", ".cjs"];
14005
14009
  function findFile(baseDir, baseName) {
14006
- const localBin = path21.resolve(baseDir, baseName);
14010
+ const localBin = path22.resolve(baseDir, baseName);
14007
14011
  if (fs18.existsSync(localBin)) return localBin;
14008
- if (sourceExt.includes(path21.extname(baseName))) return void 0;
14012
+ if (sourceExt.includes(path22.extname(baseName))) return void 0;
14009
14013
  const foundExt = sourceExt.find(
14010
14014
  (ext) => fs18.existsSync(`${localBin}${ext}`)
14011
14015
  );
@@ -14023,17 +14027,17 @@ Expecting one of '${allowedValues.join("', '")}'`);
14023
14027
  } catch (err) {
14024
14028
  resolvedScriptPath = this._scriptPath;
14025
14029
  }
14026
- executableDir = path21.resolve(
14027
- path21.dirname(resolvedScriptPath),
14030
+ executableDir = path22.resolve(
14031
+ path22.dirname(resolvedScriptPath),
14028
14032
  executableDir
14029
14033
  );
14030
14034
  }
14031
14035
  if (executableDir) {
14032
14036
  let localFile = findFile(executableDir, executableFile);
14033
14037
  if (!localFile && !subcommand._executableFile && this._scriptPath) {
14034
- const legacyName = path21.basename(
14038
+ const legacyName = path22.basename(
14035
14039
  this._scriptPath,
14036
- path21.extname(this._scriptPath)
14040
+ path22.extname(this._scriptPath)
14037
14041
  );
14038
14042
  if (legacyName !== this._name) {
14039
14043
  localFile = findFile(
@@ -14044,7 +14048,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
14044
14048
  }
14045
14049
  executableFile = localFile || executableFile;
14046
14050
  }
14047
- launchWithNode = sourceExt.includes(path21.extname(executableFile));
14051
+ launchWithNode = sourceExt.includes(path22.extname(executableFile));
14048
14052
  let proc;
14049
14053
  if (process10.platform !== "win32") {
14050
14054
  if (launchWithNode) {
@@ -14884,7 +14888,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
14884
14888
  * @return {Command}
14885
14889
  */
14886
14890
  nameFromFilename(filename) {
14887
- this._name = path21.basename(filename, path21.extname(filename));
14891
+ this._name = path22.basename(filename, path22.extname(filename));
14888
14892
  return this;
14889
14893
  }
14890
14894
  /**
@@ -14898,9 +14902,9 @@ Expecting one of '${allowedValues.join("', '")}'`);
14898
14902
  * @param {string} [path]
14899
14903
  * @return {(string|null|Command)}
14900
14904
  */
14901
- executableDir(path22) {
14902
- if (path22 === void 0) return this._executableDir;
14903
- this._executableDir = path22;
14905
+ executableDir(path23) {
14906
+ if (path23 === void 0) return this._executableDir;
14907
+ this._executableDir = path23;
14904
14908
  return this;
14905
14909
  }
14906
14910
  /**
@@ -60069,15 +60073,15 @@ var require_route = __commonJS({
60069
60073
  };
60070
60074
  }
60071
60075
  function wrapConversion(toModel, graph) {
60072
- const path21 = [graph[toModel].parent, toModel];
60076
+ const path22 = [graph[toModel].parent, toModel];
60073
60077
  let fn = conversions[graph[toModel].parent][toModel];
60074
60078
  let cur = graph[toModel].parent;
60075
60079
  while (graph[cur].parent) {
60076
- path21.unshift(graph[cur].parent);
60080
+ path22.unshift(graph[cur].parent);
60077
60081
  fn = link2(conversions[graph[cur].parent][cur], fn);
60078
60082
  cur = graph[cur].parent;
60079
60083
  }
60080
- fn.conversion = path21;
60084
+ fn.conversion = path22;
60081
60085
  return fn;
60082
60086
  }
60083
60087
  module.exports = function(fromModel) {
@@ -77212,13 +77216,13 @@ var logOutputSync = ({ serializedResult, fdNumber, state, verboseInfo, encoding,
77212
77216
  }
77213
77217
  };
77214
77218
  var writeToFiles = (serializedResult, stdioItems, outputFiles) => {
77215
- for (const { path: path21, append } of stdioItems.filter(({ type }) => FILE_TYPES.has(type))) {
77216
- const pathString = typeof path21 === "string" ? path21 : path21.toString();
77219
+ for (const { path: path22, append } of stdioItems.filter(({ type }) => FILE_TYPES.has(type))) {
77220
+ const pathString = typeof path22 === "string" ? path22 : path22.toString();
77217
77221
  if (append || outputFiles.has(pathString)) {
77218
- appendFileSync(path21, serializedResult);
77222
+ appendFileSync(path22, serializedResult);
77219
77223
  } else {
77220
77224
  outputFiles.add(pathString);
77221
- writeFileSync(path21, serializedResult);
77225
+ writeFileSync(path22, serializedResult);
77222
77226
  }
77223
77227
  }
77224
77228
  };
@@ -80269,8 +80273,8 @@ function getErrorMap() {
80269
80273
 
80270
80274
  // node_modules/zod/v3/helpers/parseUtil.js
80271
80275
  var makeIssue = (params) => {
80272
- const { data, path: path21, errorMaps, issueData } = params;
80273
- const fullPath = [...path21, ...issueData.path || []];
80276
+ const { data, path: path22, errorMaps, issueData } = params;
80277
+ const fullPath = [...path22, ...issueData.path || []];
80274
80278
  const fullIssue = {
80275
80279
  ...issueData,
80276
80280
  path: fullPath
@@ -80386,11 +80390,11 @@ var errorUtil;
80386
80390
 
80387
80391
  // node_modules/zod/v3/types.js
80388
80392
  var ParseInputLazyPath = class {
80389
- constructor(parent, value, path21, key) {
80393
+ constructor(parent, value, path22, key) {
80390
80394
  this._cachedPath = [];
80391
80395
  this.parent = parent;
80392
80396
  this.data = value;
80393
- this._path = path21;
80397
+ this._path = path22;
80394
80398
  this._key = key;
80395
80399
  }
80396
80400
  get path() {
@@ -83951,8 +83955,14 @@ var ActionSchema = external_exports.object({
83951
83955
  key: external_exports.string().min(1).max(1).optional()
83952
83956
  });
83953
83957
  var MountSettingsSchema = external_exports.object({
83954
- /** Workspace-relative path for the generated docker-compose overlay. */
83955
- overlayPath: external_exports.string().optional().default("docker-compose.dev-cockpit.yml"),
83958
+ /**
83959
+ * Override path for the generated docker-compose overlay. When unset
83960
+ * (the default), the overlay lands in the cockpit state dir alongside
83961
+ * `mount.manifest.json` — keeps the wrapper repo clean of per-developer
83962
+ * artefacts. When set, the value is workspace-relative; absolute paths
83963
+ * are honoured verbatim.
83964
+ */
83965
+ overlayPath: external_exports.string().optional(),
83956
83966
  /** Basename inside stateDir for the manifest. */
83957
83967
  manifestFile: external_exports.string().optional().default("mount.manifest.json")
83958
83968
  });
@@ -83972,7 +83982,6 @@ var BaseCockpitConfigSchema = external_exports.object({
83972
83982
  }),
83973
83983
  mounts: external_exports.array(MountSchema).optional().default([]),
83974
83984
  mount: MountSettingsSchema.optional().default({
83975
- overlayPath: "docker-compose.dev-cockpit.yml",
83976
83985
  manifestFile: "mount.manifest.json"
83977
83986
  }),
83978
83987
  /** Which pane the cockpit lands on when it boots. Profile may override. */
@@ -84041,6 +84050,48 @@ function loadConfig(filePath, opts = {}) {
84041
84050
  return config;
84042
84051
  }
84043
84052
 
84053
+ // src/core/config-discovery.ts
84054
+ import fs4 from "node:fs";
84055
+ import path7 from "node:path";
84056
+ var DiscoveryError = class extends Error {
84057
+ constructor(workspaceRoot) {
84058
+ super(
84059
+ `dev-cockpit: no cockpit.yaml found at ${workspaceRoot}/cockpit.yaml and no entry in ${manifestPath()}. Run \`dev-cockpit link <config-path>\` from this directory to register one, or pass --config <path>.`
84060
+ );
84061
+ this.workspaceRoot = workspaceRoot;
84062
+ this.name = "DiscoveryError";
84063
+ }
84064
+ };
84065
+ function discoverConfig(opts = {}) {
84066
+ const cwd = opts.cwd ?? process.cwd();
84067
+ const envConfig = opts.envConfig ?? process.env["DEV_COCKPIT_CONFIG"];
84068
+ const profileRoot = opts.workspaceDiscoverer?.()?.root;
84069
+ const workspaceRoot = profileRoot ? canonical(profileRoot) : canonical(cwd);
84070
+ if (opts.cliConfig) {
84071
+ return {
84072
+ configPath: path7.resolve(cwd, opts.cliConfig),
84073
+ workspaceRoot,
84074
+ source: "cli"
84075
+ };
84076
+ }
84077
+ if (envConfig) {
84078
+ return {
84079
+ configPath: path7.resolve(cwd, envConfig),
84080
+ workspaceRoot,
84081
+ source: "env"
84082
+ };
84083
+ }
84084
+ const localConfig = path7.join(workspaceRoot, "cockpit.yaml");
84085
+ if (fs4.existsSync(localConfig)) {
84086
+ return { configPath: localConfig, workspaceRoot, source: "workspace" };
84087
+ }
84088
+ const mapped = lookupConfig(workspaceRoot);
84089
+ if (mapped) {
84090
+ return { configPath: mapped, workspaceRoot, source: "manifest" };
84091
+ }
84092
+ throw new DiscoveryError(workspaceRoot);
84093
+ }
84094
+
84044
84095
  // node_modules/commander/esm.mjs
84045
84096
  var import_index = __toESM(require_commander(), 1);
84046
84097
  var {
@@ -84629,18 +84680,18 @@ function Health() {
84629
84680
  var import_react4 = __toESM(require_react(), 1);
84630
84681
 
84631
84682
  // src/cockpit/help/loader.ts
84632
- import fs4 from "node:fs";
84633
- import path7 from "node:path";
84683
+ import fs5 from "node:fs";
84684
+ import path8 from "node:path";
84634
84685
  import { fileURLToPath as fileURLToPath3 } from "node:url";
84635
84686
  function resolveDocsRoot(startUrl = import.meta.url) {
84636
- let dir = path7.dirname(fileURLToPath3(startUrl));
84637
- while (dir !== path7.dirname(dir)) {
84638
- const pkgJson = path7.join(dir, "package.json");
84639
- const docsIndex = path7.join(dir, "docs", "index.md");
84640
- if (fs4.existsSync(pkgJson) && fs4.existsSync(docsIndex)) {
84641
- return path7.join(dir, "docs");
84687
+ let dir = path8.dirname(fileURLToPath3(startUrl));
84688
+ while (dir !== path8.dirname(dir)) {
84689
+ const pkgJson = path8.join(dir, "package.json");
84690
+ const docsIndex = path8.join(dir, "docs", "index.md");
84691
+ if (fs5.existsSync(pkgJson) && fs5.existsSync(docsIndex)) {
84692
+ return path8.join(dir, "docs");
84642
84693
  }
84643
- dir = path7.dirname(dir);
84694
+ dir = path8.dirname(dir);
84644
84695
  }
84645
84696
  return null;
84646
84697
  }
@@ -84656,18 +84707,18 @@ function parseIndex(indexBody) {
84656
84707
  return out;
84657
84708
  }
84658
84709
  function loadPagesFromDir(docsRoot) {
84659
- const indexPath = path7.join(docsRoot, "index.md");
84710
+ const indexPath = path8.join(docsRoot, "index.md");
84660
84711
  let indexBody;
84661
84712
  try {
84662
- indexBody = fs4.readFileSync(indexPath, "utf8");
84713
+ indexBody = fs5.readFileSync(indexPath, "utf8");
84663
84714
  } catch {
84664
84715
  return [];
84665
84716
  }
84666
84717
  const pages = [{ slug: "index", title: "Index", path: indexPath, body: indexBody }];
84667
84718
  for (const entry of parseIndex(indexBody)) {
84668
- const pagePath = path7.join(docsRoot, `${entry.slug}.md`);
84719
+ const pagePath = path8.join(docsRoot, `${entry.slug}.md`);
84669
84720
  try {
84670
- const body = fs4.readFileSync(pagePath, "utf8");
84721
+ const body = fs5.readFileSync(pagePath, "utf8");
84671
84722
  pages.push({ slug: entry.slug, title: entry.title, path: pagePath, body });
84672
84723
  } catch {
84673
84724
  }
@@ -87879,7 +87930,7 @@ function useGlobalKeys(opts) {
87879
87930
  var import_react7 = __toESM(require_react(), 1);
87880
87931
 
87881
87932
  // src/health/scheduler.ts
87882
- import path8 from "node:path";
87933
+ import path9 from "node:path";
87883
87934
 
87884
87935
  // src/health/runner.ts
87885
87936
  async function runChecks(checks, triggerSet, ctx) {
@@ -87940,7 +87991,7 @@ var HealthScheduler = class {
87940
87991
  }
87941
87992
  onFsEvent(filePath) {
87942
87993
  if (!this.running) return;
87943
- const fileName = path8.basename(filePath);
87994
+ const fileName = path9.basename(filePath);
87944
87995
  const isLockfile = this.lockfileNames.has(fileName);
87945
87996
  const triggers = ["fsevent"];
87946
87997
  if (isLockfile) {
@@ -88063,7 +88114,7 @@ function resolveNotify(transition, globalConfig, perItem) {
88063
88114
 
88064
88115
  // src/health/builtin.ts
88065
88116
  import net from "node:net";
88066
- import path9 from "node:path";
88117
+ import path10 from "node:path";
88067
88118
  var containerRunning = (entry) => {
88068
88119
  const container = entry.container;
88069
88120
  if (!container) {
@@ -88150,7 +88201,7 @@ var fileExists = (entry) => {
88150
88201
  throw new Error(`health[${entry.id}]: type 'file-exists' requires 'path'`);
88151
88202
  }
88152
88203
  return async (ctx) => {
88153
- const resolved = path9.isAbsolute(target) ? target : path9.join(ctx.workspaceRoot, target);
88204
+ const resolved = path10.isAbsolute(target) ? target : path10.join(ctx.workspaceRoot, target);
88154
88205
  const exists = ctx.fs.existsSync(resolved);
88155
88206
  return {
88156
88207
  id: entry.id,
@@ -88261,7 +88312,7 @@ function safeLogger() {
88261
88312
  }
88262
88313
 
88263
88314
  // src/health/context.ts
88264
- import fs5 from "node:fs";
88315
+ import fs6 from "node:fs";
88265
88316
  var defaultExec = async (cmd, args, cwd) => {
88266
88317
  let stdout = "";
88267
88318
  const handle = spawnStream(cmd, args, {
@@ -88274,13 +88325,13 @@ var defaultExec = async (cmd, args, cwd) => {
88274
88325
  return { stdout, exitCode };
88275
88326
  };
88276
88327
  var defaultFs = {
88277
- existsSync: (p) => fs5.existsSync(p),
88278
- statSync: (p) => fs5.statSync(p),
88328
+ existsSync: (p) => fs6.existsSync(p),
88329
+ statSync: (p) => fs6.statSync(p),
88279
88330
  readdirSync: (p, opts) => {
88280
88331
  if (opts?.withFileTypes) {
88281
- return fs5.readdirSync(p, { withFileTypes: true });
88332
+ return fs6.readdirSync(p, { withFileTypes: true });
88282
88333
  }
88283
- return fs5.readdirSync(p);
88334
+ return fs6.readdirSync(p);
88284
88335
  }
88285
88336
  };
88286
88337
  function buildHealthContext(workspaceRoot, appendOutput) {
@@ -88539,8 +88590,8 @@ async function restartDockerService(deps) {
88539
88590
  }
88540
88591
 
88541
88592
  // src/docker/logs.ts
88542
- import path10 from "node:path";
88543
- import fs6 from "node:fs";
88593
+ import path11 from "node:path";
88594
+ import fs7 from "node:fs";
88544
88595
  var DEBOUNCE_MS = 3e4;
88545
88596
  var SILENT_THRESHOLD_MS = 9e4;
88546
88597
  var DockerLogTailer = class {
@@ -88567,8 +88618,8 @@ var DockerLogTailer = class {
88567
88618
  */
88568
88619
  resolveComposeFile() {
88569
88620
  if (this.opts.composeFile) {
88570
- const abs = path10.isAbsolute(this.opts.composeFile) ? this.opts.composeFile : path10.join(this.opts.workspaceRoot, this.opts.composeFile);
88571
- return fs6.existsSync(abs) ? abs : null;
88621
+ const abs = path11.isAbsolute(this.opts.composeFile) ? this.opts.composeFile : path11.join(this.opts.workspaceRoot, this.opts.composeFile);
88622
+ return fs7.existsSync(abs) ? abs : null;
88572
88623
  }
88573
88624
  return null;
88574
88625
  }
@@ -88681,8 +88732,8 @@ var DockerLogTailer = class {
88681
88732
  };
88682
88733
 
88683
88734
  // src/watchers/manager.ts
88684
- import fs7 from "node:fs";
88685
- import path12 from "node:path";
88735
+ import fs8 from "node:fs";
88736
+ import path13 from "node:path";
88686
88737
 
88687
88738
  // node_modules/chokidar/index.js
88688
88739
  import { EventEmitter as EventEmitter2 } from "node:events";
@@ -88774,7 +88825,7 @@ var ReaddirpStream = class extends Readable4 {
88774
88825
  this._directoryFilter = normalizeFilter(opts.directoryFilter);
88775
88826
  const statMethod = opts.lstat ? lstat : stat;
88776
88827
  if (wantBigintFsStats) {
88777
- this._stat = (path21) => statMethod(path21, { bigint: true });
88828
+ this._stat = (path22) => statMethod(path22, { bigint: true });
88778
88829
  } else {
88779
88830
  this._stat = statMethod;
88780
88831
  }
@@ -88799,8 +88850,8 @@ var ReaddirpStream = class extends Readable4 {
88799
88850
  const par = this.parent;
88800
88851
  const fil = par && par.files;
88801
88852
  if (fil && fil.length > 0) {
88802
- const { path: path21, depth } = par;
88803
- const slice = fil.splice(0, batch).map((dirent) => this._formatEntry(dirent, path21));
88853
+ const { path: path22, depth } = par;
88854
+ const slice = fil.splice(0, batch).map((dirent) => this._formatEntry(dirent, path22));
88804
88855
  const awaited = await Promise.all(slice);
88805
88856
  for (const entry of awaited) {
88806
88857
  if (!entry)
@@ -88840,20 +88891,20 @@ var ReaddirpStream = class extends Readable4 {
88840
88891
  this.reading = false;
88841
88892
  }
88842
88893
  }
88843
- async _exploreDir(path21, depth) {
88894
+ async _exploreDir(path22, depth) {
88844
88895
  let files;
88845
88896
  try {
88846
- files = await readdir(path21, this._rdOptions);
88897
+ files = await readdir(path22, this._rdOptions);
88847
88898
  } catch (error) {
88848
88899
  this._onError(error);
88849
88900
  }
88850
- return { files, depth, path: path21 };
88901
+ return { files, depth, path: path22 };
88851
88902
  }
88852
- async _formatEntry(dirent, path21) {
88903
+ async _formatEntry(dirent, path22) {
88853
88904
  let entry;
88854
88905
  const basename3 = this._isDirent ? dirent.name : dirent;
88855
88906
  try {
88856
- const fullPath = presolve(pjoin(path21, basename3));
88907
+ const fullPath = presolve(pjoin(path22, basename3));
88857
88908
  entry = { path: prelative(this._root, fullPath), fullPath, basename: basename3 };
88858
88909
  entry[this._statsProp] = this._isDirent ? dirent : await this._stat(fullPath);
88859
88910
  } catch (err) {
@@ -89253,16 +89304,16 @@ var delFromSet = (main, prop, item) => {
89253
89304
  };
89254
89305
  var isEmptySet = (val) => val instanceof Set ? val.size === 0 : !val;
89255
89306
  var FsWatchInstances = /* @__PURE__ */ new Map();
89256
- function createFsWatchInstance(path21, options2, listener, errHandler, emitRaw) {
89307
+ function createFsWatchInstance(path22, options2, listener, errHandler, emitRaw) {
89257
89308
  const handleEvent = (rawEvent, evPath) => {
89258
- listener(path21);
89259
- emitRaw(rawEvent, evPath, { watchedPath: path21 });
89260
- if (evPath && path21 !== evPath) {
89261
- fsWatchBroadcast(sp.resolve(path21, evPath), KEY_LISTENERS, sp.join(path21, evPath));
89309
+ listener(path22);
89310
+ emitRaw(rawEvent, evPath, { watchedPath: path22 });
89311
+ if (evPath && path22 !== evPath) {
89312
+ fsWatchBroadcast(sp.resolve(path22, evPath), KEY_LISTENERS, sp.join(path22, evPath));
89262
89313
  }
89263
89314
  };
89264
89315
  try {
89265
- return fs_watch(path21, {
89316
+ return fs_watch(path22, {
89266
89317
  persistent: options2.persistent
89267
89318
  }, handleEvent);
89268
89319
  } catch (error) {
@@ -89278,12 +89329,12 @@ var fsWatchBroadcast = (fullPath, listenerType, val1, val2, val3) => {
89278
89329
  listener(val1, val2, val3);
89279
89330
  });
89280
89331
  };
89281
- var setFsWatchListener = (path21, fullPath, options2, handlers) => {
89332
+ var setFsWatchListener = (path22, fullPath, options2, handlers) => {
89282
89333
  const { listener, errHandler, rawEmitter } = handlers;
89283
89334
  let cont = FsWatchInstances.get(fullPath);
89284
89335
  let watcher;
89285
89336
  if (!options2.persistent) {
89286
- watcher = createFsWatchInstance(path21, options2, listener, errHandler, rawEmitter);
89337
+ watcher = createFsWatchInstance(path22, options2, listener, errHandler, rawEmitter);
89287
89338
  if (!watcher)
89288
89339
  return;
89289
89340
  return watcher.close.bind(watcher);
@@ -89294,7 +89345,7 @@ var setFsWatchListener = (path21, fullPath, options2, handlers) => {
89294
89345
  addAndConvert(cont, KEY_RAW, rawEmitter);
89295
89346
  } else {
89296
89347
  watcher = createFsWatchInstance(
89297
- path21,
89348
+ path22,
89298
89349
  options2,
89299
89350
  fsWatchBroadcast.bind(null, fullPath, KEY_LISTENERS),
89300
89351
  errHandler,
@@ -89309,7 +89360,7 @@ var setFsWatchListener = (path21, fullPath, options2, handlers) => {
89309
89360
  cont.watcherUnusable = true;
89310
89361
  if (isWindows && error.code === "EPERM") {
89311
89362
  try {
89312
- const fd = await open(path21, "r");
89363
+ const fd = await open(path22, "r");
89313
89364
  await fd.close();
89314
89365
  broadcastErr(error);
89315
89366
  } catch (err) {
@@ -89340,7 +89391,7 @@ var setFsWatchListener = (path21, fullPath, options2, handlers) => {
89340
89391
  };
89341
89392
  };
89342
89393
  var FsWatchFileInstances = /* @__PURE__ */ new Map();
89343
- var setFsWatchFileListener = (path21, fullPath, options2, handlers) => {
89394
+ var setFsWatchFileListener = (path22, fullPath, options2, handlers) => {
89344
89395
  const { listener, rawEmitter } = handlers;
89345
89396
  let cont = FsWatchFileInstances.get(fullPath);
89346
89397
  const copts = cont && cont.options;
@@ -89362,7 +89413,7 @@ var setFsWatchFileListener = (path21, fullPath, options2, handlers) => {
89362
89413
  });
89363
89414
  const currmtime = curr.mtimeMs;
89364
89415
  if (curr.size !== prev.size || currmtime > prev.mtimeMs || currmtime === 0) {
89365
- foreach(cont.listeners, (listener2) => listener2(path21, curr));
89416
+ foreach(cont.listeners, (listener2) => listener2(path22, curr));
89366
89417
  }
89367
89418
  })
89368
89419
  };
@@ -89392,13 +89443,13 @@ var NodeFsHandler = class {
89392
89443
  * @param listener on fs change
89393
89444
  * @returns closer for the watcher instance
89394
89445
  */
89395
- _watchWithNodeFs(path21, listener) {
89446
+ _watchWithNodeFs(path22, listener) {
89396
89447
  const opts = this.fsw.options;
89397
- const directory = sp.dirname(path21);
89398
- const basename3 = sp.basename(path21);
89448
+ const directory = sp.dirname(path22);
89449
+ const basename3 = sp.basename(path22);
89399
89450
  const parent = this.fsw._getWatchedDir(directory);
89400
89451
  parent.add(basename3);
89401
- const absolutePath = sp.resolve(path21);
89452
+ const absolutePath = sp.resolve(path22);
89402
89453
  const options2 = {
89403
89454
  persistent: opts.persistent
89404
89455
  };
@@ -89408,12 +89459,12 @@ var NodeFsHandler = class {
89408
89459
  if (opts.usePolling) {
89409
89460
  const enableBin = opts.interval !== opts.binaryInterval;
89410
89461
  options2.interval = enableBin && isBinaryPath(basename3) ? opts.binaryInterval : opts.interval;
89411
- closer = setFsWatchFileListener(path21, absolutePath, options2, {
89462
+ closer = setFsWatchFileListener(path22, absolutePath, options2, {
89412
89463
  listener,
89413
89464
  rawEmitter: this.fsw._emitRaw
89414
89465
  });
89415
89466
  } else {
89416
- closer = setFsWatchListener(path21, absolutePath, options2, {
89467
+ closer = setFsWatchListener(path22, absolutePath, options2, {
89417
89468
  listener,
89418
89469
  errHandler: this._boundHandleError,
89419
89470
  rawEmitter: this.fsw._emitRaw
@@ -89435,7 +89486,7 @@ var NodeFsHandler = class {
89435
89486
  let prevStats = stats;
89436
89487
  if (parent.has(basename3))
89437
89488
  return;
89438
- const listener = async (path21, newStats) => {
89489
+ const listener = async (path22, newStats) => {
89439
89490
  if (!this.fsw._throttle(THROTTLE_MODE_WATCH, file, 5))
89440
89491
  return;
89441
89492
  if (!newStats || newStats.mtimeMs === 0) {
@@ -89449,11 +89500,11 @@ var NodeFsHandler = class {
89449
89500
  this.fsw._emit(EV.CHANGE, file, newStats2);
89450
89501
  }
89451
89502
  if ((isMacos || isLinux || isFreeBSD) && prevStats.ino !== newStats2.ino) {
89452
- this.fsw._closeFile(path21);
89503
+ this.fsw._closeFile(path22);
89453
89504
  prevStats = newStats2;
89454
89505
  const closer2 = this._watchWithNodeFs(file, listener);
89455
89506
  if (closer2)
89456
- this.fsw._addPathCloser(path21, closer2);
89507
+ this.fsw._addPathCloser(path22, closer2);
89457
89508
  } else {
89458
89509
  prevStats = newStats2;
89459
89510
  }
@@ -89485,7 +89536,7 @@ var NodeFsHandler = class {
89485
89536
  * @param item basename of this item
89486
89537
  * @returns true if no more processing is needed for this entry.
89487
89538
  */
89488
- async _handleSymlink(entry, directory, path21, item) {
89539
+ async _handleSymlink(entry, directory, path22, item) {
89489
89540
  if (this.fsw.closed) {
89490
89541
  return;
89491
89542
  }
@@ -89495,7 +89546,7 @@ var NodeFsHandler = class {
89495
89546
  this.fsw._incrReadyCount();
89496
89547
  let linkPath;
89497
89548
  try {
89498
- linkPath = await fsrealpath(path21);
89549
+ linkPath = await fsrealpath(path22);
89499
89550
  } catch (e) {
89500
89551
  this.fsw._emitReady();
89501
89552
  return true;
@@ -89505,12 +89556,12 @@ var NodeFsHandler = class {
89505
89556
  if (dir.has(item)) {
89506
89557
  if (this.fsw._symlinkPaths.get(full) !== linkPath) {
89507
89558
  this.fsw._symlinkPaths.set(full, linkPath);
89508
- this.fsw._emit(EV.CHANGE, path21, entry.stats);
89559
+ this.fsw._emit(EV.CHANGE, path22, entry.stats);
89509
89560
  }
89510
89561
  } else {
89511
89562
  dir.add(item);
89512
89563
  this.fsw._symlinkPaths.set(full, linkPath);
89513
- this.fsw._emit(EV.ADD, path21, entry.stats);
89564
+ this.fsw._emit(EV.ADD, path22, entry.stats);
89514
89565
  }
89515
89566
  this.fsw._emitReady();
89516
89567
  return true;
@@ -89540,9 +89591,9 @@ var NodeFsHandler = class {
89540
89591
  return;
89541
89592
  }
89542
89593
  const item = entry.path;
89543
- let path21 = sp.join(directory, item);
89594
+ let path22 = sp.join(directory, item);
89544
89595
  current.add(item);
89545
- if (entry.stats.isSymbolicLink() && await this._handleSymlink(entry, directory, path21, item)) {
89596
+ if (entry.stats.isSymbolicLink() && await this._handleSymlink(entry, directory, path22, item)) {
89546
89597
  return;
89547
89598
  }
89548
89599
  if (this.fsw.closed) {
@@ -89551,8 +89602,8 @@ var NodeFsHandler = class {
89551
89602
  }
89552
89603
  if (item === target || !target && !previous.has(item)) {
89553
89604
  this.fsw._incrReadyCount();
89554
- path21 = sp.join(dir, sp.relative(dir, path21));
89555
- this._addToNodeFs(path21, initialAdd, wh, depth + 1);
89605
+ path22 = sp.join(dir, sp.relative(dir, path22));
89606
+ this._addToNodeFs(path22, initialAdd, wh, depth + 1);
89556
89607
  }
89557
89608
  }).on(EV.ERROR, this._boundHandleError);
89558
89609
  return new Promise((resolve3, reject) => {
@@ -89621,13 +89672,13 @@ var NodeFsHandler = class {
89621
89672
  * @param depth Child path actually targeted for watch
89622
89673
  * @param target Child path actually targeted for watch
89623
89674
  */
89624
- async _addToNodeFs(path21, initialAdd, priorWh, depth, target) {
89675
+ async _addToNodeFs(path22, initialAdd, priorWh, depth, target) {
89625
89676
  const ready = this.fsw._emitReady;
89626
- if (this.fsw._isIgnored(path21) || this.fsw.closed) {
89677
+ if (this.fsw._isIgnored(path22) || this.fsw.closed) {
89627
89678
  ready();
89628
89679
  return false;
89629
89680
  }
89630
- const wh = this.fsw._getWatchHelpers(path21);
89681
+ const wh = this.fsw._getWatchHelpers(path22);
89631
89682
  if (priorWh) {
89632
89683
  wh.filterPath = (entry) => priorWh.filterPath(entry);
89633
89684
  wh.filterDir = (entry) => priorWh.filterDir(entry);
@@ -89643,8 +89694,8 @@ var NodeFsHandler = class {
89643
89694
  const follow = this.fsw.options.followSymlinks;
89644
89695
  let closer;
89645
89696
  if (stats.isDirectory()) {
89646
- const absPath = sp.resolve(path21);
89647
- const targetPath = follow ? await fsrealpath(path21) : path21;
89697
+ const absPath = sp.resolve(path22);
89698
+ const targetPath = follow ? await fsrealpath(path22) : path22;
89648
89699
  if (this.fsw.closed)
89649
89700
  return;
89650
89701
  closer = await this._handleDir(wh.watchPath, stats, initialAdd, depth, target, wh, targetPath);
@@ -89654,29 +89705,29 @@ var NodeFsHandler = class {
89654
89705
  this.fsw._symlinkPaths.set(absPath, targetPath);
89655
89706
  }
89656
89707
  } else if (stats.isSymbolicLink()) {
89657
- const targetPath = follow ? await fsrealpath(path21) : path21;
89708
+ const targetPath = follow ? await fsrealpath(path22) : path22;
89658
89709
  if (this.fsw.closed)
89659
89710
  return;
89660
89711
  const parent = sp.dirname(wh.watchPath);
89661
89712
  this.fsw._getWatchedDir(parent).add(wh.watchPath);
89662
89713
  this.fsw._emit(EV.ADD, wh.watchPath, stats);
89663
- closer = await this._handleDir(parent, stats, initialAdd, depth, path21, wh, targetPath);
89714
+ closer = await this._handleDir(parent, stats, initialAdd, depth, path22, wh, targetPath);
89664
89715
  if (this.fsw.closed)
89665
89716
  return;
89666
89717
  if (targetPath !== void 0) {
89667
- this.fsw._symlinkPaths.set(sp.resolve(path21), targetPath);
89718
+ this.fsw._symlinkPaths.set(sp.resolve(path22), targetPath);
89668
89719
  }
89669
89720
  } else {
89670
89721
  closer = this._handleFile(wh.watchPath, stats, initialAdd);
89671
89722
  }
89672
89723
  ready();
89673
89724
  if (closer)
89674
- this.fsw._addPathCloser(path21, closer);
89725
+ this.fsw._addPathCloser(path22, closer);
89675
89726
  return false;
89676
89727
  } catch (error) {
89677
89728
  if (this.fsw._handleError(error)) {
89678
89729
  ready();
89679
- return path21;
89730
+ return path22;
89680
89731
  }
89681
89732
  }
89682
89733
  }
@@ -89719,24 +89770,24 @@ function createPattern(matcher) {
89719
89770
  }
89720
89771
  return () => false;
89721
89772
  }
89722
- function normalizePath(path21) {
89723
- if (typeof path21 !== "string")
89773
+ function normalizePath(path22) {
89774
+ if (typeof path22 !== "string")
89724
89775
  throw new Error("string expected");
89725
- path21 = sp2.normalize(path21);
89726
- path21 = path21.replace(/\\/g, "/");
89776
+ path22 = sp2.normalize(path22);
89777
+ path22 = path22.replace(/\\/g, "/");
89727
89778
  let prepend = false;
89728
- if (path21.startsWith("//"))
89779
+ if (path22.startsWith("//"))
89729
89780
  prepend = true;
89730
- path21 = path21.replace(DOUBLE_SLASH_RE, "/");
89781
+ path22 = path22.replace(DOUBLE_SLASH_RE, "/");
89731
89782
  if (prepend)
89732
- path21 = "/" + path21;
89733
- return path21;
89783
+ path22 = "/" + path22;
89784
+ return path22;
89734
89785
  }
89735
89786
  function matchPatterns(patterns, testString, stats) {
89736
- const path21 = normalizePath(testString);
89787
+ const path22 = normalizePath(testString);
89737
89788
  for (let index = 0; index < patterns.length; index++) {
89738
89789
  const pattern = patterns[index];
89739
- if (pattern(path21, stats)) {
89790
+ if (pattern(path22, stats)) {
89740
89791
  return true;
89741
89792
  }
89742
89793
  }
@@ -89774,19 +89825,19 @@ var toUnix = (string) => {
89774
89825
  }
89775
89826
  return str;
89776
89827
  };
89777
- var normalizePathToUnix = (path21) => toUnix(sp2.normalize(toUnix(path21)));
89778
- var normalizeIgnored = (cwd = "") => (path21) => {
89779
- if (typeof path21 === "string") {
89780
- return normalizePathToUnix(sp2.isAbsolute(path21) ? path21 : sp2.join(cwd, path21));
89828
+ var normalizePathToUnix = (path22) => toUnix(sp2.normalize(toUnix(path22)));
89829
+ var normalizeIgnored = (cwd = "") => (path22) => {
89830
+ if (typeof path22 === "string") {
89831
+ return normalizePathToUnix(sp2.isAbsolute(path22) ? path22 : sp2.join(cwd, path22));
89781
89832
  } else {
89782
- return path21;
89833
+ return path22;
89783
89834
  }
89784
89835
  };
89785
- var getAbsolutePath = (path21, cwd) => {
89786
- if (sp2.isAbsolute(path21)) {
89787
- return path21;
89836
+ var getAbsolutePath = (path22, cwd) => {
89837
+ if (sp2.isAbsolute(path22)) {
89838
+ return path22;
89788
89839
  }
89789
- return sp2.join(cwd, path21);
89840
+ return sp2.join(cwd, path22);
89790
89841
  };
89791
89842
  var EMPTY_SET = Object.freeze(/* @__PURE__ */ new Set());
89792
89843
  var DirEntry = class {
@@ -89851,10 +89902,10 @@ var WatchHelper = class {
89851
89902
  dirParts;
89852
89903
  followSymlinks;
89853
89904
  statMethod;
89854
- constructor(path21, follow, fsw) {
89905
+ constructor(path22, follow, fsw) {
89855
89906
  this.fsw = fsw;
89856
- const watchPath = path21;
89857
- this.path = path21 = path21.replace(REPLACER_RE, "");
89907
+ const watchPath = path22;
89908
+ this.path = path22 = path22.replace(REPLACER_RE, "");
89858
89909
  this.watchPath = watchPath;
89859
89910
  this.fullWatchPath = sp2.resolve(watchPath);
89860
89911
  this.dirParts = [];
@@ -89994,20 +90045,20 @@ var FSWatcher = class extends EventEmitter2 {
89994
90045
  this._closePromise = void 0;
89995
90046
  let paths = unifyPaths(paths_);
89996
90047
  if (cwd) {
89997
- paths = paths.map((path21) => {
89998
- const absPath = getAbsolutePath(path21, cwd);
90048
+ paths = paths.map((path22) => {
90049
+ const absPath = getAbsolutePath(path22, cwd);
89999
90050
  return absPath;
90000
90051
  });
90001
90052
  }
90002
- paths.forEach((path21) => {
90003
- this._removeIgnoredPath(path21);
90053
+ paths.forEach((path22) => {
90054
+ this._removeIgnoredPath(path22);
90004
90055
  });
90005
90056
  this._userIgnored = void 0;
90006
90057
  if (!this._readyCount)
90007
90058
  this._readyCount = 0;
90008
90059
  this._readyCount += paths.length;
90009
- Promise.all(paths.map(async (path21) => {
90010
- const res = await this._nodeFsHandler._addToNodeFs(path21, !_internal, void 0, 0, _origAdd);
90060
+ Promise.all(paths.map(async (path22) => {
90061
+ const res = await this._nodeFsHandler._addToNodeFs(path22, !_internal, void 0, 0, _origAdd);
90011
90062
  if (res)
90012
90063
  this._emitReady();
90013
90064
  return res;
@@ -90029,17 +90080,17 @@ var FSWatcher = class extends EventEmitter2 {
90029
90080
  return this;
90030
90081
  const paths = unifyPaths(paths_);
90031
90082
  const { cwd } = this.options;
90032
- paths.forEach((path21) => {
90033
- if (!sp2.isAbsolute(path21) && !this._closers.has(path21)) {
90083
+ paths.forEach((path22) => {
90084
+ if (!sp2.isAbsolute(path22) && !this._closers.has(path22)) {
90034
90085
  if (cwd)
90035
- path21 = sp2.join(cwd, path21);
90036
- path21 = sp2.resolve(path21);
90086
+ path22 = sp2.join(cwd, path22);
90087
+ path22 = sp2.resolve(path22);
90037
90088
  }
90038
- this._closePath(path21);
90039
- this._addIgnoredPath(path21);
90040
- if (this._watched.has(path21)) {
90089
+ this._closePath(path22);
90090
+ this._addIgnoredPath(path22);
90091
+ if (this._watched.has(path22)) {
90041
90092
  this._addIgnoredPath({
90042
- path: path21,
90093
+ path: path22,
90043
90094
  recursive: true
90044
90095
  });
90045
90096
  }
@@ -90103,38 +90154,38 @@ var FSWatcher = class extends EventEmitter2 {
90103
90154
  * @param stats arguments to be passed with event
90104
90155
  * @returns the error if defined, otherwise the value of the FSWatcher instance's `closed` flag
90105
90156
  */
90106
- async _emit(event, path21, stats) {
90157
+ async _emit(event, path22, stats) {
90107
90158
  if (this.closed)
90108
90159
  return;
90109
90160
  const opts = this.options;
90110
90161
  if (isWindows)
90111
- path21 = sp2.normalize(path21);
90162
+ path22 = sp2.normalize(path22);
90112
90163
  if (opts.cwd)
90113
- path21 = sp2.relative(opts.cwd, path21);
90114
- const args = [path21];
90164
+ path22 = sp2.relative(opts.cwd, path22);
90165
+ const args = [path22];
90115
90166
  if (stats != null)
90116
90167
  args.push(stats);
90117
90168
  const awf = opts.awaitWriteFinish;
90118
90169
  let pw;
90119
- if (awf && (pw = this._pendingWrites.get(path21))) {
90170
+ if (awf && (pw = this._pendingWrites.get(path22))) {
90120
90171
  pw.lastChange = /* @__PURE__ */ new Date();
90121
90172
  return this;
90122
90173
  }
90123
90174
  if (opts.atomic) {
90124
90175
  if (event === EVENTS.UNLINK) {
90125
- this._pendingUnlinks.set(path21, [event, ...args]);
90176
+ this._pendingUnlinks.set(path22, [event, ...args]);
90126
90177
  setTimeout(() => {
90127
- this._pendingUnlinks.forEach((entry, path22) => {
90178
+ this._pendingUnlinks.forEach((entry, path23) => {
90128
90179
  this.emit(...entry);
90129
90180
  this.emit(EVENTS.ALL, ...entry);
90130
- this._pendingUnlinks.delete(path22);
90181
+ this._pendingUnlinks.delete(path23);
90131
90182
  });
90132
90183
  }, typeof opts.atomic === "number" ? opts.atomic : 100);
90133
90184
  return this;
90134
90185
  }
90135
- if (event === EVENTS.ADD && this._pendingUnlinks.has(path21)) {
90186
+ if (event === EVENTS.ADD && this._pendingUnlinks.has(path22)) {
90136
90187
  event = EVENTS.CHANGE;
90137
- this._pendingUnlinks.delete(path21);
90188
+ this._pendingUnlinks.delete(path22);
90138
90189
  }
90139
90190
  }
90140
90191
  if (awf && (event === EVENTS.ADD || event === EVENTS.CHANGE) && this._readyEmitted) {
@@ -90152,16 +90203,16 @@ var FSWatcher = class extends EventEmitter2 {
90152
90203
  this.emitWithAll(event, args);
90153
90204
  }
90154
90205
  };
90155
- this._awaitWriteFinish(path21, awf.stabilityThreshold, event, awfEmit);
90206
+ this._awaitWriteFinish(path22, awf.stabilityThreshold, event, awfEmit);
90156
90207
  return this;
90157
90208
  }
90158
90209
  if (event === EVENTS.CHANGE) {
90159
- const isThrottled = !this._throttle(EVENTS.CHANGE, path21, 50);
90210
+ const isThrottled = !this._throttle(EVENTS.CHANGE, path22, 50);
90160
90211
  if (isThrottled)
90161
90212
  return this;
90162
90213
  }
90163
90214
  if (opts.alwaysStat && stats === void 0 && (event === EVENTS.ADD || event === EVENTS.ADD_DIR || event === EVENTS.CHANGE)) {
90164
- const fullPath = opts.cwd ? sp2.join(opts.cwd, path21) : path21;
90215
+ const fullPath = opts.cwd ? sp2.join(opts.cwd, path22) : path22;
90165
90216
  let stats2;
90166
90217
  try {
90167
90218
  stats2 = await stat3(fullPath);
@@ -90192,23 +90243,23 @@ var FSWatcher = class extends EventEmitter2 {
90192
90243
  * @param timeout duration of time to suppress duplicate actions
90193
90244
  * @returns tracking object or false if action should be suppressed
90194
90245
  */
90195
- _throttle(actionType, path21, timeout) {
90246
+ _throttle(actionType, path22, timeout) {
90196
90247
  if (!this._throttled.has(actionType)) {
90197
90248
  this._throttled.set(actionType, /* @__PURE__ */ new Map());
90198
90249
  }
90199
90250
  const action = this._throttled.get(actionType);
90200
90251
  if (!action)
90201
90252
  throw new Error("invalid throttle");
90202
- const actionPath = action.get(path21);
90253
+ const actionPath = action.get(path22);
90203
90254
  if (actionPath) {
90204
90255
  actionPath.count++;
90205
90256
  return false;
90206
90257
  }
90207
90258
  let timeoutObject;
90208
90259
  const clear = () => {
90209
- const item = action.get(path21);
90260
+ const item = action.get(path22);
90210
90261
  const count2 = item ? item.count : 0;
90211
- action.delete(path21);
90262
+ action.delete(path22);
90212
90263
  clearTimeout(timeoutObject);
90213
90264
  if (item)
90214
90265
  clearTimeout(item.timeoutObject);
@@ -90216,7 +90267,7 @@ var FSWatcher = class extends EventEmitter2 {
90216
90267
  };
90217
90268
  timeoutObject = setTimeout(clear, timeout);
90218
90269
  const thr = { timeoutObject, clear, count: 0 };
90219
- action.set(path21, thr);
90270
+ action.set(path22, thr);
90220
90271
  return thr;
90221
90272
  }
90222
90273
  _incrReadyCount() {
@@ -90230,44 +90281,44 @@ var FSWatcher = class extends EventEmitter2 {
90230
90281
  * @param event
90231
90282
  * @param awfEmit Callback to be called when ready for event to be emitted.
90232
90283
  */
90233
- _awaitWriteFinish(path21, threshold, event, awfEmit) {
90284
+ _awaitWriteFinish(path22, threshold, event, awfEmit) {
90234
90285
  const awf = this.options.awaitWriteFinish;
90235
90286
  if (typeof awf !== "object")
90236
90287
  return;
90237
90288
  const pollInterval = awf.pollInterval;
90238
90289
  let timeoutHandler;
90239
- let fullPath = path21;
90240
- if (this.options.cwd && !sp2.isAbsolute(path21)) {
90241
- fullPath = sp2.join(this.options.cwd, path21);
90290
+ let fullPath = path22;
90291
+ if (this.options.cwd && !sp2.isAbsolute(path22)) {
90292
+ fullPath = sp2.join(this.options.cwd, path22);
90242
90293
  }
90243
90294
  const now = /* @__PURE__ */ new Date();
90244
90295
  const writes = this._pendingWrites;
90245
90296
  function awaitWriteFinishFn(prevStat) {
90246
90297
  statcb(fullPath, (err, curStat) => {
90247
- if (err || !writes.has(path21)) {
90298
+ if (err || !writes.has(path22)) {
90248
90299
  if (err && err.code !== "ENOENT")
90249
90300
  awfEmit(err);
90250
90301
  return;
90251
90302
  }
90252
90303
  const now2 = Number(/* @__PURE__ */ new Date());
90253
90304
  if (prevStat && curStat.size !== prevStat.size) {
90254
- writes.get(path21).lastChange = now2;
90305
+ writes.get(path22).lastChange = now2;
90255
90306
  }
90256
- const pw = writes.get(path21);
90307
+ const pw = writes.get(path22);
90257
90308
  const df = now2 - pw.lastChange;
90258
90309
  if (df >= threshold) {
90259
- writes.delete(path21);
90310
+ writes.delete(path22);
90260
90311
  awfEmit(void 0, curStat);
90261
90312
  } else {
90262
90313
  timeoutHandler = setTimeout(awaitWriteFinishFn, pollInterval, curStat);
90263
90314
  }
90264
90315
  });
90265
90316
  }
90266
- if (!writes.has(path21)) {
90267
- writes.set(path21, {
90317
+ if (!writes.has(path22)) {
90318
+ writes.set(path22, {
90268
90319
  lastChange: now,
90269
90320
  cancelWait: () => {
90270
- writes.delete(path21);
90321
+ writes.delete(path22);
90271
90322
  clearTimeout(timeoutHandler);
90272
90323
  return event;
90273
90324
  }
@@ -90278,8 +90329,8 @@ var FSWatcher = class extends EventEmitter2 {
90278
90329
  /**
90279
90330
  * Determines whether user has asked to ignore this path.
90280
90331
  */
90281
- _isIgnored(path21, stats) {
90282
- if (this.options.atomic && DOT_RE.test(path21))
90332
+ _isIgnored(path22, stats) {
90333
+ if (this.options.atomic && DOT_RE.test(path22))
90283
90334
  return true;
90284
90335
  if (!this._userIgnored) {
90285
90336
  const { cwd } = this.options;
@@ -90289,17 +90340,17 @@ var FSWatcher = class extends EventEmitter2 {
90289
90340
  const list3 = [...ignoredPaths.map(normalizeIgnored(cwd)), ...ignored];
90290
90341
  this._userIgnored = anymatch(list3, void 0);
90291
90342
  }
90292
- return this._userIgnored(path21, stats);
90343
+ return this._userIgnored(path22, stats);
90293
90344
  }
90294
- _isntIgnored(path21, stat4) {
90295
- return !this._isIgnored(path21, stat4);
90345
+ _isntIgnored(path22, stat4) {
90346
+ return !this._isIgnored(path22, stat4);
90296
90347
  }
90297
90348
  /**
90298
90349
  * Provides a set of common helpers and properties relating to symlink handling.
90299
90350
  * @param path file or directory pattern being watched
90300
90351
  */
90301
- _getWatchHelpers(path21) {
90302
- return new WatchHelper(path21, this.options.followSymlinks, this);
90352
+ _getWatchHelpers(path22) {
90353
+ return new WatchHelper(path22, this.options.followSymlinks, this);
90303
90354
  }
90304
90355
  // Directory helpers
90305
90356
  // -----------------
@@ -90331,63 +90382,63 @@ var FSWatcher = class extends EventEmitter2 {
90331
90382
  * @param item base path of item/directory
90332
90383
  */
90333
90384
  _remove(directory, item, isDirectory) {
90334
- const path21 = sp2.join(directory, item);
90335
- const fullPath = sp2.resolve(path21);
90336
- isDirectory = isDirectory != null ? isDirectory : this._watched.has(path21) || this._watched.has(fullPath);
90337
- if (!this._throttle("remove", path21, 100))
90385
+ const path22 = sp2.join(directory, item);
90386
+ const fullPath = sp2.resolve(path22);
90387
+ isDirectory = isDirectory != null ? isDirectory : this._watched.has(path22) || this._watched.has(fullPath);
90388
+ if (!this._throttle("remove", path22, 100))
90338
90389
  return;
90339
90390
  if (!isDirectory && this._watched.size === 1) {
90340
90391
  this.add(directory, item, true);
90341
90392
  }
90342
- const wp = this._getWatchedDir(path21);
90393
+ const wp = this._getWatchedDir(path22);
90343
90394
  const nestedDirectoryChildren = wp.getChildren();
90344
- nestedDirectoryChildren.forEach((nested) => this._remove(path21, nested));
90395
+ nestedDirectoryChildren.forEach((nested) => this._remove(path22, nested));
90345
90396
  const parent = this._getWatchedDir(directory);
90346
90397
  const wasTracked = parent.has(item);
90347
90398
  parent.remove(item);
90348
90399
  if (this._symlinkPaths.has(fullPath)) {
90349
90400
  this._symlinkPaths.delete(fullPath);
90350
90401
  }
90351
- let relPath = path21;
90402
+ let relPath = path22;
90352
90403
  if (this.options.cwd)
90353
- relPath = sp2.relative(this.options.cwd, path21);
90404
+ relPath = sp2.relative(this.options.cwd, path22);
90354
90405
  if (this.options.awaitWriteFinish && this._pendingWrites.has(relPath)) {
90355
90406
  const event = this._pendingWrites.get(relPath).cancelWait();
90356
90407
  if (event === EVENTS.ADD)
90357
90408
  return;
90358
90409
  }
90359
- this._watched.delete(path21);
90410
+ this._watched.delete(path22);
90360
90411
  this._watched.delete(fullPath);
90361
90412
  const eventName = isDirectory ? EVENTS.UNLINK_DIR : EVENTS.UNLINK;
90362
- if (wasTracked && !this._isIgnored(path21))
90363
- this._emit(eventName, path21);
90364
- this._closePath(path21);
90413
+ if (wasTracked && !this._isIgnored(path22))
90414
+ this._emit(eventName, path22);
90415
+ this._closePath(path22);
90365
90416
  }
90366
90417
  /**
90367
90418
  * Closes all watchers for a path
90368
90419
  */
90369
- _closePath(path21) {
90370
- this._closeFile(path21);
90371
- const dir = sp2.dirname(path21);
90372
- this._getWatchedDir(dir).remove(sp2.basename(path21));
90420
+ _closePath(path22) {
90421
+ this._closeFile(path22);
90422
+ const dir = sp2.dirname(path22);
90423
+ this._getWatchedDir(dir).remove(sp2.basename(path22));
90373
90424
  }
90374
90425
  /**
90375
90426
  * Closes only file-specific watchers
90376
90427
  */
90377
- _closeFile(path21) {
90378
- const closers = this._closers.get(path21);
90428
+ _closeFile(path22) {
90429
+ const closers = this._closers.get(path22);
90379
90430
  if (!closers)
90380
90431
  return;
90381
90432
  closers.forEach((closer) => closer());
90382
- this._closers.delete(path21);
90433
+ this._closers.delete(path22);
90383
90434
  }
90384
- _addPathCloser(path21, closer) {
90435
+ _addPathCloser(path22, closer) {
90385
90436
  if (!closer)
90386
90437
  return;
90387
- let list3 = this._closers.get(path21);
90438
+ let list3 = this._closers.get(path22);
90388
90439
  if (!list3) {
90389
90440
  list3 = [];
90390
- this._closers.set(path21, list3);
90441
+ this._closers.set(path22, list3);
90391
90442
  }
90392
90443
  list3.push(closer);
90393
90444
  }
@@ -90432,7 +90483,7 @@ function mapPathToRepo(filePath, repos) {
90432
90483
  }
90433
90484
 
90434
90485
  // src/lint/reactive.ts
90435
- import path11 from "node:path";
90486
+ import path12 from "node:path";
90436
90487
  var EXT_TO_LINT_KEY = {
90437
90488
  ".js": "js",
90438
90489
  ".jsx": "js",
@@ -90447,7 +90498,7 @@ var EXT_TO_LINT_KEY = {
90447
90498
  ".php": "php"
90448
90499
  };
90449
90500
  function selectLintCommand(filePath, lintConfig) {
90450
- const ext = path11.extname(filePath).toLowerCase();
90501
+ const ext = path12.extname(filePath).toLowerCase();
90451
90502
  const key = EXT_TO_LINT_KEY[ext];
90452
90503
  if (!key) return void 0;
90453
90504
  return lintConfig[key];
@@ -90522,7 +90573,7 @@ async function runLintCmd(filePath, cmd, opts) {
90522
90573
  ts: Date.now(),
90523
90574
  source: repoName,
90524
90575
  severity: "info",
90525
- text: `lint passed for ${path11.basename(filePath)}`
90576
+ text: `lint passed for ${path12.basename(filePath)}`
90526
90577
  });
90527
90578
  onLintResult("pass");
90528
90579
  } else {
@@ -90530,7 +90581,7 @@ async function runLintCmd(filePath, cmd, opts) {
90530
90581
  ts: Date.now(),
90531
90582
  source: repoName,
90532
90583
  severity: "error",
90533
- text: `lint FAILED for ${path11.basename(filePath)} (exit ${code})`
90584
+ text: `lint FAILED for ${path12.basename(filePath)} (exit ${code})`
90534
90585
  });
90535
90586
  onLintResult("fail");
90536
90587
  }
@@ -90540,7 +90591,7 @@ async function runLintCmd(filePath, cmd, opts) {
90540
90591
  function detectUsePolling() {
90541
90592
  if (process.env["DEV_COCKPIT_CHOKIDAR_POLLING"] === "1") return true;
90542
90593
  try {
90543
- const version = fs7.readFileSync("/proc/version", "utf8");
90594
+ const version = fs8.readFileSync("/proc/version", "utf8");
90544
90595
  return /microsoft|wsl/i.test(version);
90545
90596
  } catch {
90546
90597
  return false;
@@ -90572,7 +90623,7 @@ var WatcherManager = class {
90572
90623
  const globs = [];
90573
90624
  for (const [, managed] of this.repos) {
90574
90625
  for (const pattern of managed.config.discover) {
90575
- globs.push(path12.join(managed.rootDir, pattern));
90626
+ globs.push(path13.join(managed.rootDir, pattern));
90576
90627
  }
90577
90628
  }
90578
90629
  if (globs.length === 0) return;
@@ -90803,48 +90854,6 @@ function buildActionRegistry(configActions, profileActions = []) {
90803
90854
  return Array.from(byId.values());
90804
90855
  }
90805
90856
 
90806
- // src/core/config-discovery.ts
90807
- import fs8 from "node:fs";
90808
- import path13 from "node:path";
90809
- var DiscoveryError = class extends Error {
90810
- constructor(workspaceRoot) {
90811
- super(
90812
- `dev-cockpit: no cockpit.yaml found at ${workspaceRoot}/cockpit.yaml and no entry in ${manifestPath()}. Run \`dev-cockpit link <config-path>\` from this directory to register one, or pass --config <path>.`
90813
- );
90814
- this.workspaceRoot = workspaceRoot;
90815
- this.name = "DiscoveryError";
90816
- }
90817
- };
90818
- function discoverConfig(opts = {}) {
90819
- const cwd = opts.cwd ?? process.cwd();
90820
- const envConfig = opts.envConfig ?? process.env["DEV_COCKPIT_CONFIG"];
90821
- const profileRoot = opts.workspaceDiscoverer?.()?.root;
90822
- const workspaceRoot = profileRoot ? canonical(profileRoot) : canonical(cwd);
90823
- if (opts.cliConfig) {
90824
- return {
90825
- configPath: path13.resolve(cwd, opts.cliConfig),
90826
- workspaceRoot,
90827
- source: "cli"
90828
- };
90829
- }
90830
- if (envConfig) {
90831
- return {
90832
- configPath: path13.resolve(cwd, envConfig),
90833
- workspaceRoot,
90834
- source: "env"
90835
- };
90836
- }
90837
- const localConfig = path13.join(workspaceRoot, "cockpit.yaml");
90838
- if (fs8.existsSync(localConfig)) {
90839
- return { configPath: localConfig, workspaceRoot, source: "workspace" };
90840
- }
90841
- const mapped = lookupConfig(workspaceRoot);
90842
- if (mapped) {
90843
- return { configPath: mapped, workspaceRoot, source: "manifest" };
90844
- }
90845
- throw new DiscoveryError(workspaceRoot);
90846
- }
90847
-
90848
90857
  // src/commands/dev.ts
90849
90858
  async function devCommand(opts = {}) {
90850
90859
  const profile = opts.profile;
@@ -92221,7 +92230,7 @@ doctor failed: ${err instanceof Error ? err.message : String(err)}
92221
92230
  }
92222
92231
 
92223
92232
  // src/commands/mount.ts
92224
- import path19 from "node:path";
92233
+ import path20 from "node:path";
92225
92234
  import fs15 from "node:fs";
92226
92235
 
92227
92236
  // src/mount/manifest.ts
@@ -92307,9 +92316,19 @@ function renderDockerOverlay(mounts, opts) {
92307
92316
  `;
92308
92317
  }
92309
92318
 
92319
+ // src/mount/overlay-path.ts
92320
+ import path18 from "node:path";
92321
+ function resolveOverlayPath(opts) {
92322
+ if (!opts.configOverride) {
92323
+ return path18.join(opts.stateDir, "dev-mount-overlay.yml");
92324
+ }
92325
+ if (path18.isAbsolute(opts.configOverride)) return opts.configOverride;
92326
+ return path18.resolve(opts.workspaceRoot, opts.configOverride);
92327
+ }
92328
+
92310
92329
  // src/mount/symlinks.ts
92311
92330
  import fs14 from "node:fs";
92312
- import path18 from "node:path";
92331
+ import path19 from "node:path";
92313
92332
  function applyManagedSymlinks(workspaceRoot, mounts, strategy) {
92314
92333
  const report = { created: [], skipped: [] };
92315
92334
  for (const m of mounts) {
@@ -92332,7 +92351,7 @@ function applyManagedSymlinks(workspaceRoot, mounts, strategy) {
92332
92351
  }
92333
92352
  } catch {
92334
92353
  }
92335
- fs14.mkdirSync(path18.dirname(linkPath), { recursive: true });
92354
+ fs14.mkdirSync(path19.dirname(linkPath), { recursive: true });
92336
92355
  fs14.symlinkSync(m.hostPath, linkPath);
92337
92356
  report.created.push(linkPath);
92338
92357
  }
@@ -92450,9 +92469,13 @@ async function resolveContext(opts) {
92450
92469
  process.exit(1);
92451
92470
  }
92452
92471
  const providerMounts = await profile?.mountCandidatesProvider?.() ?? [];
92453
- const overlayPath = path19.resolve(workspaceRoot, config.mount.overlayPath);
92454
92472
  const paths = getStatePaths(workspaceRoot, { appName: config.appName });
92455
- const manifestPath2 = path19.join(paths.stateDir, config.mount.manifestFile);
92473
+ const overlayPath = resolveOverlayPath({
92474
+ stateDir: paths.stateDir,
92475
+ workspaceRoot,
92476
+ configOverride: config.mount.overlayPath
92477
+ });
92478
+ const manifestPath2 = path20.join(paths.stateDir, config.mount.manifestFile);
92456
92479
  return {
92457
92480
  configPath,
92458
92481
  workspaceRoot,
@@ -92514,7 +92537,7 @@ async function mountCommand(opts = {}) {
92514
92537
  return;
92515
92538
  }
92516
92539
  }
92517
- fs15.mkdirSync(path19.dirname(overlayPath), { recursive: true });
92540
+ fs15.mkdirSync(path20.dirname(overlayPath), { recursive: true });
92518
92541
  fs15.writeFileSync(overlayPath, renderDockerOverlay(selected, { service }), "utf8");
92519
92542
  process.stdout.write(`dev-cockpit mount: wrote ${overlayPath}
92520
92543
  `);
@@ -92546,7 +92569,7 @@ async function mountCommand(opts = {}) {
92546
92569
  await profile.onMountApply(hookCtx);
92547
92570
  } else {
92548
92571
  process.stdout.write(
92549
- ` Apply with: docker compose -f <your-compose>.yml -f ${path19.basename(overlayPath)} up -d
92572
+ ` Apply with: docker compose -f <your-compose>.yml -f ${path20.basename(overlayPath)} up -d
92550
92573
  `
92551
92574
  );
92552
92575
  }
@@ -92656,9 +92679,9 @@ async function mountClearCommand(opts = {}) {
92656
92679
  // src/commands/migrate-config.ts
92657
92680
  var import_yaml2 = __toESM(require_dist(), 1);
92658
92681
  import fs16 from "node:fs";
92659
- import path20 from "node:path";
92682
+ import path21 from "node:path";
92660
92683
  async function migrateConfigCommand(opts = {}) {
92661
- const configPath = path20.resolve(opts.config ?? "cockpit.yaml");
92684
+ const configPath = path21.resolve(opts.config ?? "cockpit.yaml");
92662
92685
  if (!fs16.existsSync(configPath)) {
92663
92686
  process.stderr.write(`dev-cockpit migrate-config: no file at ${configPath}.
92664
92687
  `);
@@ -92760,15 +92783,15 @@ function buildCli(opts = {}) {
92760
92783
  }
92761
92784
  if (!hasCommand(program2, "link")) {
92762
92785
  const linkCmd = program2.command("link").description("Register the current directory as using a cockpit.yaml that lives elsewhere").argument("<config-path>", "Path to the cockpit.yaml to associate with this directory").action(async (configPath) => {
92763
- const { linkAddCommand } = await import("./link-HXNII7EU.js");
92786
+ const { linkAddCommand } = await import("./link-VWT2VQH6.js");
92764
92787
  linkAddCommand({ configPath });
92765
92788
  });
92766
92789
  linkCmd.command("list").description("Print all registered project \u2192 config mappings").action(async () => {
92767
- const { linkListCommand } = await import("./link-HXNII7EU.js");
92790
+ const { linkListCommand } = await import("./link-VWT2VQH6.js");
92768
92791
  linkListCommand();
92769
92792
  });
92770
92793
  linkCmd.command("remove").description("Unregister the current directory from the manifest").action(async () => {
92771
- const { linkRemoveCommand } = await import("./link-HXNII7EU.js");
92794
+ const { linkRemoveCommand } = await import("./link-VWT2VQH6.js");
92772
92795
  linkRemoveCommand();
92773
92796
  });
92774
92797
  }
@@ -92832,6 +92855,7 @@ export {
92832
92855
  DEFAULT_HIGHLIGHT_PATTERNS,
92833
92856
  DEBOUNCE_MS as DOCKER_NOTIFY_DEBOUNCE_MS,
92834
92857
  SILENT_THRESHOLD_MS as DOCKER_SILENT_THRESHOLD_MS,
92858
+ DiscoveryError,
92835
92859
  DockerLogTailer,
92836
92860
  FALLBACK_PAGE,
92837
92861
  FilterModal,
@@ -92855,6 +92879,7 @@ export {
92855
92879
  buildHealthContext,
92856
92880
  buildHealthRegistry,
92857
92881
  buildTemplate,
92882
+ canonical,
92858
92883
  cockpitStore,
92859
92884
  compileHighlights,
92860
92885
  createLogger,
@@ -92862,6 +92887,7 @@ export {
92862
92887
  detectBrokenSymlinks,
92863
92888
  detectTransitions,
92864
92889
  devCommand,
92890
+ discoverConfig,
92865
92891
  dispatchRemediation,
92866
92892
  doctorCommand,
92867
92893
  emitEvent,
@@ -92877,9 +92903,12 @@ export {
92877
92903
  initLogger,
92878
92904
  killAllSpawned,
92879
92905
  killSpawnedByTag,
92906
+ listMappings,
92880
92907
  loadConfig,
92881
92908
  loadHelpPages,
92882
92909
  loadPagesFromDir,
92910
+ lookupConfig,
92911
+ manifestPath,
92883
92912
  mapPathToRepo,
92884
92913
  matchHighlights,
92885
92914
  mergeMounts,
@@ -92891,13 +92920,16 @@ export {
92891
92920
  notifyTransitions,
92892
92921
  parseIndex,
92893
92922
  readGitInfo,
92923
+ readManifest,
92894
92924
  readMountManifest,
92895
92925
  removeManagedSymlinks,
92926
+ removeMapping,
92896
92927
  renderDockerOverlay,
92897
92928
  renderMarkdown,
92898
92929
  renderWizardYaml,
92899
92930
  resolveDocsRoot,
92900
92931
  resolveNotify,
92932
+ resolveOverlayPath,
92901
92933
  restartDockerService,
92902
92934
  runAllLints,
92903
92935
  runChecks,
@@ -92907,6 +92939,7 @@ export {
92907
92939
  runRemediation,
92908
92940
  scheduleLint,
92909
92941
  selectLintCommand,
92942
+ setMapping,
92910
92943
  spawnStream,
92911
92944
  useCockpitStore,
92912
92945
  useGlobalKeys,