@inkeep/agents-cli 0.0.0-dev-20251030195812 → 0.0.0-dev-20251030231543

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.
Files changed (3) hide show
  1. package/README.md +1 -1
  2. package/dist/index.js +936 -897
  3. package/package.json +4 -4
package/dist/index.js CHANGED
@@ -1026,9 +1026,9 @@ var init_request = __esm({
1026
1026
  routeIndex = 0;
1027
1027
  path;
1028
1028
  bodyCache = {};
1029
- constructor(request, path4 = "/", matchResult = [[]]) {
1029
+ constructor(request, path5 = "/", matchResult = [[]]) {
1030
1030
  this.raw = request;
1031
- this.path = path4;
1031
+ this.path = path5;
1032
1032
  this.#matchResult = matchResult;
1033
1033
  this.#validatedData = {};
1034
1034
  }
@@ -5191,16 +5191,16 @@ var require_util = __commonJS({
5191
5191
  }
5192
5192
  exports.urlGenerate = urlGenerate;
5193
5193
  function normalize(aPath) {
5194
- var path4 = aPath;
5194
+ var path5 = aPath;
5195
5195
  var url = urlParse(aPath);
5196
5196
  if (url) {
5197
5197
  if (!url.path) {
5198
5198
  return aPath;
5199
5199
  }
5200
- path4 = url.path;
5200
+ path5 = url.path;
5201
5201
  }
5202
- var isAbsolute = exports.isAbsolute(path4);
5203
- var parts = path4.split(/\/+/);
5202
+ var isAbsolute = exports.isAbsolute(path5);
5203
+ var parts = path5.split(/\/+/);
5204
5204
  for (var part, up = 0, i = parts.length - 1; i >= 0; i--) {
5205
5205
  part = parts[i];
5206
5206
  if (part === ".") {
@@ -5217,15 +5217,15 @@ var require_util = __commonJS({
5217
5217
  }
5218
5218
  }
5219
5219
  }
5220
- path4 = parts.join("/");
5221
- if (path4 === "") {
5222
- path4 = isAbsolute ? "/" : ".";
5220
+ path5 = parts.join("/");
5221
+ if (path5 === "") {
5222
+ path5 = isAbsolute ? "/" : ".";
5223
5223
  }
5224
5224
  if (url) {
5225
- url.path = path4;
5225
+ url.path = path5;
5226
5226
  return urlGenerate(url);
5227
5227
  }
5228
- return path4;
5228
+ return path5;
5229
5229
  }
5230
5230
  exports.normalize = normalize;
5231
5231
  function join15(aRoot, aPath) {
@@ -6865,7 +6865,7 @@ var require_source_map_support = __commonJS({
6865
6865
  "use strict";
6866
6866
  init_esm_shims();
6867
6867
  var SourceMapConsumer = require_source_map().SourceMapConsumer;
6868
- var path4 = __require("path");
6868
+ var path5 = __require("path");
6869
6869
  var fs5;
6870
6870
  try {
6871
6871
  fs5 = __require("fs");
@@ -6926,18 +6926,18 @@ var require_source_map_support = __commonJS({
6926
6926
  };
6927
6927
  }
6928
6928
  var retrieveFile = handlerExec(retrieveFileHandlers);
6929
- retrieveFileHandlers.push(function(path5) {
6930
- path5 = path5.trim();
6931
- if (/^file:/.test(path5)) {
6932
- path5 = path5.replace(/file:\/\/\/(\w:)?/, function(protocol, drive) {
6929
+ retrieveFileHandlers.push(function(path6) {
6930
+ path6 = path6.trim();
6931
+ if (/^file:/.test(path6)) {
6932
+ path6 = path6.replace(/file:\/\/\/(\w:)?/, function(protocol, drive) {
6933
6933
  return drive ? "" : (
6934
6934
  // file:///C:/dir/file -> C:/dir/file
6935
6935
  "/"
6936
6936
  );
6937
6937
  });
6938
6938
  }
6939
- if (path5 in fileContentsCache) {
6940
- return fileContentsCache[path5];
6939
+ if (path6 in fileContentsCache) {
6940
+ return fileContentsCache[path6];
6941
6941
  }
6942
6942
  var contents = "";
6943
6943
  try {
@@ -6945,7 +6945,7 @@ var require_source_map_support = __commonJS({
6945
6945
  var xhr = new XMLHttpRequest();
6946
6946
  xhr.open(
6947
6947
  "GET",
6948
- path5,
6948
+ path6,
6949
6949
  /** async */
6950
6950
  false
6951
6951
  );
@@ -6953,24 +6953,24 @@ var require_source_map_support = __commonJS({
6953
6953
  if (xhr.readyState === 4 && xhr.status === 200) {
6954
6954
  contents = xhr.responseText;
6955
6955
  }
6956
- } else if (fs5.existsSync(path5)) {
6957
- contents = fs5.readFileSync(path5, "utf8");
6956
+ } else if (fs5.existsSync(path6)) {
6957
+ contents = fs5.readFileSync(path6, "utf8");
6958
6958
  }
6959
6959
  } catch (er) {
6960
6960
  }
6961
- return fileContentsCache[path5] = contents;
6961
+ return fileContentsCache[path6] = contents;
6962
6962
  });
6963
6963
  function supportRelativeURL(file, url) {
6964
6964
  if (!file) return url;
6965
- var dir = path4.dirname(file);
6965
+ var dir = path5.dirname(file);
6966
6966
  var match2 = /^\w+:\/\/[^\/]*/.exec(dir);
6967
6967
  var protocol = match2 ? match2[0] : "";
6968
6968
  var startPath = dir.slice(protocol.length);
6969
6969
  if (protocol && /^\/\w\:/.test(startPath)) {
6970
6970
  protocol += "/";
6971
- return protocol + path4.resolve(dir.slice(protocol.length), url).replace(/\\/g, "/");
6971
+ return protocol + path5.resolve(dir.slice(protocol.length), url).replace(/\\/g, "/");
6972
6972
  }
6973
- return protocol + path4.resolve(dir.slice(protocol.length), url);
6973
+ return protocol + path5.resolve(dir.slice(protocol.length), url);
6974
6974
  }
6975
6975
  function retrieveSourceMapURL(source) {
6976
6976
  var fileData;
@@ -15207,17 +15207,17 @@ ${lanes.join("\n")}
15207
15207
  }
15208
15208
  function createSingleWatcherPerName(cache, useCaseSensitiveFileNames2, name, callback, createWatcher) {
15209
15209
  const toCanonicalFileName = createGetCanonicalFileName(useCaseSensitiveFileNames2);
15210
- const path4 = toCanonicalFileName(name);
15211
- const existing = cache.get(path4);
15210
+ const path5 = toCanonicalFileName(name);
15211
+ const existing = cache.get(path5);
15212
15212
  if (existing) {
15213
15213
  existing.callbacks.push(callback);
15214
15214
  } else {
15215
- cache.set(path4, {
15215
+ cache.set(path5, {
15216
15216
  watcher: createWatcher(
15217
15217
  // Cant infer types correctly so lets satisfy checker
15218
15218
  (param1, param2, param3) => {
15219
15219
  var _a;
15220
- return (_a = cache.get(path4)) == null ? void 0 : _a.callbacks.slice().forEach((cb) => cb(param1, param2, param3));
15220
+ return (_a = cache.get(path5)) == null ? void 0 : _a.callbacks.slice().forEach((cb) => cb(param1, param2, param3));
15221
15221
  }
15222
15222
  ),
15223
15223
  callbacks: [callback]
@@ -15225,10 +15225,10 @@ ${lanes.join("\n")}
15225
15225
  }
15226
15226
  return {
15227
15227
  close: () => {
15228
- const watcher = cache.get(path4);
15228
+ const watcher = cache.get(path5);
15229
15229
  if (!watcher) return;
15230
15230
  if (!orderedRemoveItem(watcher.callbacks, callback) || watcher.callbacks.length) return;
15231
- cache.delete(path4);
15231
+ cache.delete(path5);
15232
15232
  closeFileWatcherOf(watcher);
15233
15233
  }
15234
15234
  };
@@ -15480,13 +15480,13 @@ ${lanes.join("\n")}
15480
15480
  (newChildWatches || (newChildWatches = [])).push(childWatcher);
15481
15481
  }
15482
15482
  }
15483
- function isIgnoredPath(path4, options) {
15484
- return some(ignoredPaths, (searchPath) => isInPath(path4, searchPath)) || isIgnoredByWatchOptions(path4, options, useCaseSensitiveFileNames2, getCurrentDirectory);
15483
+ function isIgnoredPath(path5, options) {
15484
+ return some(ignoredPaths, (searchPath) => isInPath(path5, searchPath)) || isIgnoredByWatchOptions(path5, options, useCaseSensitiveFileNames2, getCurrentDirectory);
15485
15485
  }
15486
- function isInPath(path4, searchPath) {
15487
- if (path4.includes(searchPath)) return true;
15486
+ function isInPath(path5, searchPath) {
15487
+ if (path5.includes(searchPath)) return true;
15488
15488
  if (useCaseSensitiveFileNames2) return false;
15489
- return toCanonicalFilePath(path4).includes(searchPath);
15489
+ return toCanonicalFilePath(path5).includes(searchPath);
15490
15490
  }
15491
15491
  }
15492
15492
  var FileSystemEntryKind = /* @__PURE__ */ ((FileSystemEntryKind2) => {
@@ -15864,8 +15864,8 @@ ${lanes.join("\n")}
15864
15864
  }
15865
15865
  function patchWriteFileEnsuringDirectory(sys2) {
15866
15866
  const originalWriteFile = sys2.writeFile;
15867
- sys2.writeFile = (path4, data, writeBom) => writeFileEnsuringDirectories(
15868
- path4,
15867
+ sys2.writeFile = (path5, data, writeBom) => writeFileEnsuringDirectories(
15868
+ path5,
15869
15869
  data,
15870
15870
  !!writeBom,
15871
15871
  (path22, data2, writeByteOrderMark) => originalWriteFile.call(sys2, path22, data2, writeByteOrderMark),
@@ -15909,7 +15909,7 @@ ${lanes.join("\n")}
15909
15909
  // Node 4.0 `fs.watch` function supports the "recursive" option on both OSX and Windows
15910
15910
  // (ref: https://github.com/nodejs/node/pull/2649 and https://github.com/Microsoft/TypeScript/issues/4643)
15911
15911
  fsSupportsRecursiveFsWatch,
15912
- getAccessibleSortedChildDirectories: (path4) => getAccessibleFileSystemEntries(path4).directories,
15912
+ getAccessibleSortedChildDirectories: (path5) => getAccessibleFileSystemEntries(path5).directories,
15913
15913
  realpath,
15914
15914
  tscWatchFile: process.env.TSC_WATCHFILE,
15915
15915
  useNonPollingWatchers: !!process.env.TSC_NONPOLLING_WATCHER,
@@ -15936,7 +15936,7 @@ ${lanes.join("\n")}
15936
15936
  watchFile: watchFile2,
15937
15937
  watchDirectory,
15938
15938
  preferNonRecursiveWatch: !fsSupportsRecursiveFsWatch,
15939
- resolvePath: (path4) => _path.resolve(path4),
15939
+ resolvePath: (path5) => _path.resolve(path5),
15940
15940
  fileExists,
15941
15941
  directoryExists,
15942
15942
  getAccessibleFileSystemEntries,
@@ -15971,8 +15971,8 @@ ${lanes.join("\n")}
15971
15971
  }
15972
15972
  return process.memoryUsage().heapUsed;
15973
15973
  },
15974
- getFileSize(path4) {
15975
- const stat = statSync2(path4);
15974
+ getFileSize(path5) {
15975
+ const stat = statSync2(path5);
15976
15976
  if (stat == null ? void 0 : stat.isFile()) {
15977
15977
  return stat.size;
15978
15978
  }
@@ -16016,14 +16016,14 @@ ${lanes.join("\n")}
16016
16016
  }
16017
16017
  };
16018
16018
  return nodeSystem;
16019
- function statSync2(path4) {
16019
+ function statSync2(path5) {
16020
16020
  try {
16021
- return _fs.statSync(path4, statSyncOptions);
16021
+ return _fs.statSync(path5, statSyncOptions);
16022
16022
  } catch {
16023
16023
  return void 0;
16024
16024
  }
16025
16025
  }
16026
- function enableCPUProfiler(path4, cb) {
16026
+ function enableCPUProfiler(path5, cb) {
16027
16027
  if (activeSession) {
16028
16028
  cb();
16029
16029
  return false;
@@ -16038,7 +16038,7 @@ ${lanes.join("\n")}
16038
16038
  session.post("Profiler.enable", () => {
16039
16039
  session.post("Profiler.start", () => {
16040
16040
  activeSession = session;
16041
- profilePath = path4;
16041
+ profilePath = path5;
16042
16042
  cb();
16043
16043
  });
16044
16044
  });
@@ -16182,9 +16182,9 @@ ${lanes.join("\n")}
16182
16182
  }
16183
16183
  }
16184
16184
  }
16185
- function getAccessibleFileSystemEntries(path4) {
16185
+ function getAccessibleFileSystemEntries(path5) {
16186
16186
  try {
16187
- const entries = _fs.readdirSync(path4 || ".", { withFileTypes: true });
16187
+ const entries = _fs.readdirSync(path5 || ".", { withFileTypes: true });
16188
16188
  const files = [];
16189
16189
  const directories = [];
16190
16190
  for (const dirent of entries) {
@@ -16194,7 +16194,7 @@ ${lanes.join("\n")}
16194
16194
  }
16195
16195
  let stat;
16196
16196
  if (typeof dirent === "string" || dirent.isSymbolicLink()) {
16197
- const name = combinePaths(path4, entry);
16197
+ const name = combinePaths(path5, entry);
16198
16198
  stat = statSync2(name);
16199
16199
  if (!stat) {
16200
16200
  continue;
@@ -16215,11 +16215,11 @@ ${lanes.join("\n")}
16215
16215
  return emptyFileSystemEntries;
16216
16216
  }
16217
16217
  }
16218
- function readDirectory(path4, extensions, excludes, includes, depth) {
16219
- return matchFiles(path4, extensions, excludes, includes, useCaseSensitiveFileNames2, process.cwd(), depth, getAccessibleFileSystemEntries, realpath);
16218
+ function readDirectory(path5, extensions, excludes, includes, depth) {
16219
+ return matchFiles(path5, extensions, excludes, includes, useCaseSensitiveFileNames2, process.cwd(), depth, getAccessibleFileSystemEntries, realpath);
16220
16220
  }
16221
- function fileSystemEntryExists(path4, entryKind) {
16222
- const stat = statSync2(path4);
16221
+ function fileSystemEntryExists(path5, entryKind) {
16222
+ const stat = statSync2(path5);
16223
16223
  if (!stat) {
16224
16224
  return false;
16225
16225
  }
@@ -16232,47 +16232,47 @@ ${lanes.join("\n")}
16232
16232
  return false;
16233
16233
  }
16234
16234
  }
16235
- function fileExists(path4) {
16235
+ function fileExists(path5) {
16236
16236
  return fileSystemEntryExists(
16237
- path4,
16237
+ path5,
16238
16238
  0
16239
16239
  /* File */
16240
16240
  );
16241
16241
  }
16242
- function directoryExists(path4) {
16242
+ function directoryExists(path5) {
16243
16243
  return fileSystemEntryExists(
16244
- path4,
16244
+ path5,
16245
16245
  1
16246
16246
  /* Directory */
16247
16247
  );
16248
16248
  }
16249
- function getDirectories(path4) {
16250
- return getAccessibleFileSystemEntries(path4).directories.slice();
16249
+ function getDirectories(path5) {
16250
+ return getAccessibleFileSystemEntries(path5).directories.slice();
16251
16251
  }
16252
- function fsRealPathHandlingLongPath(path4) {
16253
- return path4.length < 260 ? _fs.realpathSync.native(path4) : _fs.realpathSync(path4);
16252
+ function fsRealPathHandlingLongPath(path5) {
16253
+ return path5.length < 260 ? _fs.realpathSync.native(path5) : _fs.realpathSync(path5);
16254
16254
  }
16255
- function realpath(path4) {
16255
+ function realpath(path5) {
16256
16256
  try {
16257
- return fsRealpath(path4);
16257
+ return fsRealpath(path5);
16258
16258
  } catch {
16259
- return path4;
16259
+ return path5;
16260
16260
  }
16261
16261
  }
16262
- function getModifiedTime3(path4) {
16262
+ function getModifiedTime3(path5) {
16263
16263
  var _a;
16264
- return (_a = statSync2(path4)) == null ? void 0 : _a.mtime;
16264
+ return (_a = statSync2(path5)) == null ? void 0 : _a.mtime;
16265
16265
  }
16266
- function setModifiedTime(path4, time) {
16266
+ function setModifiedTime(path5, time) {
16267
16267
  try {
16268
- _fs.utimesSync(path4, time, time);
16268
+ _fs.utimesSync(path5, time, time);
16269
16269
  } catch {
16270
16270
  return;
16271
16271
  }
16272
16272
  }
16273
- function deleteFile(path4) {
16273
+ function deleteFile(path5) {
16274
16274
  try {
16275
- return _fs.unlinkSync(path4);
16275
+ return _fs.unlinkSync(path5);
16276
16276
  } catch {
16277
16277
  return;
16278
16278
  }
@@ -16312,41 +16312,41 @@ ${lanes.join("\n")}
16312
16312
  function isAnyDirectorySeparator(charCode) {
16313
16313
  return charCode === 47 || charCode === 92;
16314
16314
  }
16315
- function isUrl(path4) {
16316
- return getEncodedRootLength(path4) < 0;
16315
+ function isUrl(path5) {
16316
+ return getEncodedRootLength(path5) < 0;
16317
16317
  }
16318
- function isRootedDiskPath(path4) {
16319
- return getEncodedRootLength(path4) > 0;
16318
+ function isRootedDiskPath(path5) {
16319
+ return getEncodedRootLength(path5) > 0;
16320
16320
  }
16321
- function isDiskPathRoot(path4) {
16322
- const rootLength = getEncodedRootLength(path4);
16323
- return rootLength > 0 && rootLength === path4.length;
16321
+ function isDiskPathRoot(path5) {
16322
+ const rootLength = getEncodedRootLength(path5);
16323
+ return rootLength > 0 && rootLength === path5.length;
16324
16324
  }
16325
- function pathIsAbsolute(path4) {
16326
- return getEncodedRootLength(path4) !== 0;
16325
+ function pathIsAbsolute(path5) {
16326
+ return getEncodedRootLength(path5) !== 0;
16327
16327
  }
16328
- function pathIsRelative(path4) {
16329
- return /^\.\.?(?:$|[\\/])/.test(path4);
16328
+ function pathIsRelative(path5) {
16329
+ return /^\.\.?(?:$|[\\/])/.test(path5);
16330
16330
  }
16331
- function pathIsBareSpecifier(path4) {
16332
- return !pathIsAbsolute(path4) && !pathIsRelative(path4);
16331
+ function pathIsBareSpecifier(path5) {
16332
+ return !pathIsAbsolute(path5) && !pathIsRelative(path5);
16333
16333
  }
16334
16334
  function hasExtension(fileName) {
16335
16335
  return getBaseFileName(fileName).includes(".");
16336
16336
  }
16337
- function fileExtensionIs(path4, extension) {
16338
- return path4.length > extension.length && endsWith(path4, extension);
16337
+ function fileExtensionIs(path5, extension) {
16338
+ return path5.length > extension.length && endsWith(path5, extension);
16339
16339
  }
16340
- function fileExtensionIsOneOf(path4, extensions) {
16340
+ function fileExtensionIsOneOf(path5, extensions) {
16341
16341
  for (const extension of extensions) {
16342
- if (fileExtensionIs(path4, extension)) {
16342
+ if (fileExtensionIs(path5, extension)) {
16343
16343
  return true;
16344
16344
  }
16345
16345
  }
16346
16346
  return false;
16347
16347
  }
16348
- function hasTrailingDirectorySeparator(path4) {
16349
- return path4.length > 0 && isAnyDirectorySeparator(path4.charCodeAt(path4.length - 1));
16348
+ function hasTrailingDirectorySeparator(path5) {
16349
+ return path5.length > 0 && isAnyDirectorySeparator(path5.charCodeAt(path5.length - 1));
16350
16350
  }
16351
16351
  function isVolumeCharacter(charCode) {
16352
16352
  return charCode >= 97 && charCode <= 122 || charCode >= 65 && charCode <= 90;
@@ -16360,111 +16360,111 @@ ${lanes.join("\n")}
16360
16360
  }
16361
16361
  return -1;
16362
16362
  }
16363
- function getEncodedRootLength(path4) {
16364
- if (!path4) return 0;
16365
- const ch0 = path4.charCodeAt(0);
16363
+ function getEncodedRootLength(path5) {
16364
+ if (!path5) return 0;
16365
+ const ch0 = path5.charCodeAt(0);
16366
16366
  if (ch0 === 47 || ch0 === 92) {
16367
- if (path4.charCodeAt(1) !== ch0) return 1;
16368
- const p1 = path4.indexOf(ch0 === 47 ? directorySeparator : altDirectorySeparator, 2);
16369
- if (p1 < 0) return path4.length;
16367
+ if (path5.charCodeAt(1) !== ch0) return 1;
16368
+ const p1 = path5.indexOf(ch0 === 47 ? directorySeparator : altDirectorySeparator, 2);
16369
+ if (p1 < 0) return path5.length;
16370
16370
  return p1 + 1;
16371
16371
  }
16372
- if (isVolumeCharacter(ch0) && path4.charCodeAt(1) === 58) {
16373
- const ch2 = path4.charCodeAt(2);
16372
+ if (isVolumeCharacter(ch0) && path5.charCodeAt(1) === 58) {
16373
+ const ch2 = path5.charCodeAt(2);
16374
16374
  if (ch2 === 47 || ch2 === 92) return 3;
16375
- if (path4.length === 2) return 2;
16375
+ if (path5.length === 2) return 2;
16376
16376
  }
16377
- const schemeEnd = path4.indexOf(urlSchemeSeparator);
16377
+ const schemeEnd = path5.indexOf(urlSchemeSeparator);
16378
16378
  if (schemeEnd !== -1) {
16379
16379
  const authorityStart = schemeEnd + urlSchemeSeparator.length;
16380
- const authorityEnd = path4.indexOf(directorySeparator, authorityStart);
16380
+ const authorityEnd = path5.indexOf(directorySeparator, authorityStart);
16381
16381
  if (authorityEnd !== -1) {
16382
- const scheme = path4.slice(0, schemeEnd);
16383
- const authority = path4.slice(authorityStart, authorityEnd);
16384
- if (scheme === "file" && (authority === "" || authority === "localhost") && isVolumeCharacter(path4.charCodeAt(authorityEnd + 1))) {
16385
- const volumeSeparatorEnd = getFileUrlVolumeSeparatorEnd(path4, authorityEnd + 2);
16382
+ const scheme = path5.slice(0, schemeEnd);
16383
+ const authority = path5.slice(authorityStart, authorityEnd);
16384
+ if (scheme === "file" && (authority === "" || authority === "localhost") && isVolumeCharacter(path5.charCodeAt(authorityEnd + 1))) {
16385
+ const volumeSeparatorEnd = getFileUrlVolumeSeparatorEnd(path5, authorityEnd + 2);
16386
16386
  if (volumeSeparatorEnd !== -1) {
16387
- if (path4.charCodeAt(volumeSeparatorEnd) === 47) {
16387
+ if (path5.charCodeAt(volumeSeparatorEnd) === 47) {
16388
16388
  return ~(volumeSeparatorEnd + 1);
16389
16389
  }
16390
- if (volumeSeparatorEnd === path4.length) {
16390
+ if (volumeSeparatorEnd === path5.length) {
16391
16391
  return ~volumeSeparatorEnd;
16392
16392
  }
16393
16393
  }
16394
16394
  }
16395
16395
  return ~(authorityEnd + 1);
16396
16396
  }
16397
- return ~path4.length;
16397
+ return ~path5.length;
16398
16398
  }
16399
16399
  return 0;
16400
16400
  }
16401
- function getRootLength(path4) {
16402
- const rootLength = getEncodedRootLength(path4);
16401
+ function getRootLength(path5) {
16402
+ const rootLength = getEncodedRootLength(path5);
16403
16403
  return rootLength < 0 ? ~rootLength : rootLength;
16404
16404
  }
16405
- function getDirectoryPath(path4) {
16406
- path4 = normalizeSlashes(path4);
16407
- const rootLength = getRootLength(path4);
16408
- if (rootLength === path4.length) return path4;
16409
- path4 = removeTrailingDirectorySeparator(path4);
16410
- return path4.slice(0, Math.max(rootLength, path4.lastIndexOf(directorySeparator)));
16411
- }
16412
- function getBaseFileName(path4, extensions, ignoreCase) {
16413
- path4 = normalizeSlashes(path4);
16414
- const rootLength = getRootLength(path4);
16415
- if (rootLength === path4.length) return "";
16416
- path4 = removeTrailingDirectorySeparator(path4);
16417
- const name = path4.slice(Math.max(getRootLength(path4), path4.lastIndexOf(directorySeparator) + 1));
16405
+ function getDirectoryPath(path5) {
16406
+ path5 = normalizeSlashes(path5);
16407
+ const rootLength = getRootLength(path5);
16408
+ if (rootLength === path5.length) return path5;
16409
+ path5 = removeTrailingDirectorySeparator(path5);
16410
+ return path5.slice(0, Math.max(rootLength, path5.lastIndexOf(directorySeparator)));
16411
+ }
16412
+ function getBaseFileName(path5, extensions, ignoreCase) {
16413
+ path5 = normalizeSlashes(path5);
16414
+ const rootLength = getRootLength(path5);
16415
+ if (rootLength === path5.length) return "";
16416
+ path5 = removeTrailingDirectorySeparator(path5);
16417
+ const name = path5.slice(Math.max(getRootLength(path5), path5.lastIndexOf(directorySeparator) + 1));
16418
16418
  const extension = extensions !== void 0 && ignoreCase !== void 0 ? getAnyExtensionFromPath(name, extensions, ignoreCase) : void 0;
16419
16419
  return extension ? name.slice(0, name.length - extension.length) : name;
16420
16420
  }
16421
- function tryGetExtensionFromPath(path4, extension, stringEqualityComparer) {
16421
+ function tryGetExtensionFromPath(path5, extension, stringEqualityComparer) {
16422
16422
  if (!startsWith(extension, ".")) extension = "." + extension;
16423
- if (path4.length >= extension.length && path4.charCodeAt(path4.length - extension.length) === 46) {
16424
- const pathExtension = path4.slice(path4.length - extension.length);
16423
+ if (path5.length >= extension.length && path5.charCodeAt(path5.length - extension.length) === 46) {
16424
+ const pathExtension = path5.slice(path5.length - extension.length);
16425
16425
  if (stringEqualityComparer(pathExtension, extension)) {
16426
16426
  return pathExtension;
16427
16427
  }
16428
16428
  }
16429
16429
  }
16430
- function getAnyExtensionFromPathWorker(path4, extensions, stringEqualityComparer) {
16430
+ function getAnyExtensionFromPathWorker(path5, extensions, stringEqualityComparer) {
16431
16431
  if (typeof extensions === "string") {
16432
- return tryGetExtensionFromPath(path4, extensions, stringEqualityComparer) || "";
16432
+ return tryGetExtensionFromPath(path5, extensions, stringEqualityComparer) || "";
16433
16433
  }
16434
16434
  for (const extension of extensions) {
16435
- const result = tryGetExtensionFromPath(path4, extension, stringEqualityComparer);
16435
+ const result = tryGetExtensionFromPath(path5, extension, stringEqualityComparer);
16436
16436
  if (result) return result;
16437
16437
  }
16438
16438
  return "";
16439
16439
  }
16440
- function getAnyExtensionFromPath(path4, extensions, ignoreCase) {
16440
+ function getAnyExtensionFromPath(path5, extensions, ignoreCase) {
16441
16441
  if (extensions) {
16442
- return getAnyExtensionFromPathWorker(removeTrailingDirectorySeparator(path4), extensions, ignoreCase ? equateStringsCaseInsensitive : equateStringsCaseSensitive);
16442
+ return getAnyExtensionFromPathWorker(removeTrailingDirectorySeparator(path5), extensions, ignoreCase ? equateStringsCaseInsensitive : equateStringsCaseSensitive);
16443
16443
  }
16444
- const baseFileName = getBaseFileName(path4);
16444
+ const baseFileName = getBaseFileName(path5);
16445
16445
  const extensionIndex = baseFileName.lastIndexOf(".");
16446
16446
  if (extensionIndex >= 0) {
16447
16447
  return baseFileName.substring(extensionIndex);
16448
16448
  }
16449
16449
  return "";
16450
16450
  }
16451
- function pathComponents(path4, rootLength) {
16452
- const root = path4.substring(0, rootLength);
16453
- const rest = path4.substring(rootLength).split(directorySeparator);
16451
+ function pathComponents(path5, rootLength) {
16452
+ const root = path5.substring(0, rootLength);
16453
+ const rest = path5.substring(rootLength).split(directorySeparator);
16454
16454
  if (rest.length && !lastOrUndefined(rest)) rest.pop();
16455
16455
  return [root, ...rest];
16456
16456
  }
16457
- function getPathComponents(path4, currentDirectory = "") {
16458
- path4 = combinePaths(currentDirectory, path4);
16459
- return pathComponents(path4, getRootLength(path4));
16457
+ function getPathComponents(path5, currentDirectory = "") {
16458
+ path5 = combinePaths(currentDirectory, path5);
16459
+ return pathComponents(path5, getRootLength(path5));
16460
16460
  }
16461
16461
  function getPathFromPathComponents(pathComponents2, length2) {
16462
16462
  if (pathComponents2.length === 0) return "";
16463
16463
  const root = pathComponents2[0] && ensureTrailingDirectorySeparator(pathComponents2[0]);
16464
16464
  return root + pathComponents2.slice(1, length2).join(directorySeparator);
16465
16465
  }
16466
- function normalizeSlashes(path4) {
16467
- return path4.includes("\\") ? path4.replace(backslashRegExp, directorySeparator) : path4;
16466
+ function normalizeSlashes(path5) {
16467
+ return path5.includes("\\") ? path5.replace(backslashRegExp, directorySeparator) : path5;
16468
16468
  }
16469
16469
  function reducePathComponents(components) {
16470
16470
  if (!some(components)) return [];
@@ -16485,39 +16485,39 @@ ${lanes.join("\n")}
16485
16485
  }
16486
16486
  return reduced;
16487
16487
  }
16488
- function combinePaths(path4, ...paths) {
16489
- if (path4) path4 = normalizeSlashes(path4);
16488
+ function combinePaths(path5, ...paths) {
16489
+ if (path5) path5 = normalizeSlashes(path5);
16490
16490
  for (let relativePath of paths) {
16491
16491
  if (!relativePath) continue;
16492
16492
  relativePath = normalizeSlashes(relativePath);
16493
- if (!path4 || getRootLength(relativePath) !== 0) {
16494
- path4 = relativePath;
16493
+ if (!path5 || getRootLength(relativePath) !== 0) {
16494
+ path5 = relativePath;
16495
16495
  } else {
16496
- path4 = ensureTrailingDirectorySeparator(path4) + relativePath;
16496
+ path5 = ensureTrailingDirectorySeparator(path5) + relativePath;
16497
16497
  }
16498
16498
  }
16499
- return path4;
16499
+ return path5;
16500
16500
  }
16501
- function resolvePath(path4, ...paths) {
16502
- return normalizePath(some(paths) ? combinePaths(path4, ...paths) : normalizeSlashes(path4));
16501
+ function resolvePath(path5, ...paths) {
16502
+ return normalizePath(some(paths) ? combinePaths(path5, ...paths) : normalizeSlashes(path5));
16503
16503
  }
16504
- function getNormalizedPathComponents(path4, currentDirectory) {
16505
- return reducePathComponents(getPathComponents(path4, currentDirectory));
16504
+ function getNormalizedPathComponents(path5, currentDirectory) {
16505
+ return reducePathComponents(getPathComponents(path5, currentDirectory));
16506
16506
  }
16507
- function getNormalizedAbsolutePath(path4, currentDirectory) {
16508
- let rootLength = getRootLength(path4);
16507
+ function getNormalizedAbsolutePath(path5, currentDirectory) {
16508
+ let rootLength = getRootLength(path5);
16509
16509
  if (rootLength === 0 && currentDirectory) {
16510
- path4 = combinePaths(currentDirectory, path4);
16511
- rootLength = getRootLength(path4);
16510
+ path5 = combinePaths(currentDirectory, path5);
16511
+ rootLength = getRootLength(path5);
16512
16512
  } else {
16513
- path4 = normalizeSlashes(path4);
16513
+ path5 = normalizeSlashes(path5);
16514
16514
  }
16515
- const simpleNormalized = simpleNormalizePath(path4);
16515
+ const simpleNormalized = simpleNormalizePath(path5);
16516
16516
  if (simpleNormalized !== void 0) {
16517
16517
  return simpleNormalized.length > rootLength ? removeTrailingDirectorySeparator(simpleNormalized) : simpleNormalized;
16518
16518
  }
16519
- const length2 = path4.length;
16520
- const root = path4.substring(0, rootLength);
16519
+ const length2 = path5.length;
16520
+ const root = path5.substring(0, rootLength);
16521
16521
  let normalized;
16522
16522
  let index2 = rootLength;
16523
16523
  let segmentStart = index2;
@@ -16525,23 +16525,23 @@ ${lanes.join("\n")}
16525
16525
  let seenNonDotDotSegment = rootLength !== 0;
16526
16526
  while (index2 < length2) {
16527
16527
  segmentStart = index2;
16528
- let ch = path4.charCodeAt(index2);
16528
+ let ch = path5.charCodeAt(index2);
16529
16529
  while (ch === 47 && index2 + 1 < length2) {
16530
16530
  index2++;
16531
- ch = path4.charCodeAt(index2);
16531
+ ch = path5.charCodeAt(index2);
16532
16532
  }
16533
16533
  if (index2 > segmentStart) {
16534
- normalized ?? (normalized = path4.substring(0, segmentStart - 1));
16534
+ normalized ?? (normalized = path5.substring(0, segmentStart - 1));
16535
16535
  segmentStart = index2;
16536
16536
  }
16537
- let segmentEnd = path4.indexOf(directorySeparator, index2 + 1);
16537
+ let segmentEnd = path5.indexOf(directorySeparator, index2 + 1);
16538
16538
  if (segmentEnd === -1) {
16539
16539
  segmentEnd = length2;
16540
16540
  }
16541
16541
  const segmentLength = segmentEnd - segmentStart;
16542
- if (segmentLength === 1 && path4.charCodeAt(index2) === 46) {
16543
- normalized ?? (normalized = path4.substring(0, normalizedUpTo));
16544
- } else if (segmentLength === 2 && path4.charCodeAt(index2) === 46 && path4.charCodeAt(index2 + 1) === 46) {
16542
+ if (segmentLength === 1 && path5.charCodeAt(index2) === 46) {
16543
+ normalized ?? (normalized = path5.substring(0, normalizedUpTo));
16544
+ } else if (segmentLength === 2 && path5.charCodeAt(index2) === 46 && path5.charCodeAt(index2 + 1) === 46) {
16545
16545
  if (!seenNonDotDotSegment) {
16546
16546
  if (normalized !== void 0) {
16547
16547
  normalized += normalized.length === rootLength ? ".." : "/..";
@@ -16550,9 +16550,9 @@ ${lanes.join("\n")}
16550
16550
  }
16551
16551
  } else if (normalized === void 0) {
16552
16552
  if (normalizedUpTo - 2 >= 0) {
16553
- normalized = path4.substring(0, Math.max(rootLength, path4.lastIndexOf(directorySeparator, normalizedUpTo - 2)));
16553
+ normalized = path5.substring(0, Math.max(rootLength, path5.lastIndexOf(directorySeparator, normalizedUpTo - 2)));
16554
16554
  } else {
16555
- normalized = path4.substring(0, normalizedUpTo);
16555
+ normalized = path5.substring(0, normalizedUpTo);
16556
16556
  }
16557
16557
  } else {
16558
16558
  const lastSlash = normalized.lastIndexOf(directorySeparator);
@@ -16570,36 +16570,36 @@ ${lanes.join("\n")}
16570
16570
  normalized += directorySeparator;
16571
16571
  }
16572
16572
  seenNonDotDotSegment = true;
16573
- normalized += path4.substring(segmentStart, segmentEnd);
16573
+ normalized += path5.substring(segmentStart, segmentEnd);
16574
16574
  } else {
16575
16575
  seenNonDotDotSegment = true;
16576
16576
  normalizedUpTo = segmentEnd;
16577
16577
  }
16578
16578
  index2 = segmentEnd + 1;
16579
16579
  }
16580
- return normalized ?? (length2 > rootLength ? removeTrailingDirectorySeparator(path4) : path4);
16580
+ return normalized ?? (length2 > rootLength ? removeTrailingDirectorySeparator(path5) : path5);
16581
16581
  }
16582
- function normalizePath(path4) {
16583
- path4 = normalizeSlashes(path4);
16584
- let normalized = simpleNormalizePath(path4);
16582
+ function normalizePath(path5) {
16583
+ path5 = normalizeSlashes(path5);
16584
+ let normalized = simpleNormalizePath(path5);
16585
16585
  if (normalized !== void 0) {
16586
16586
  return normalized;
16587
16587
  }
16588
- normalized = getNormalizedAbsolutePath(path4, "");
16589
- return normalized && hasTrailingDirectorySeparator(path4) ? ensureTrailingDirectorySeparator(normalized) : normalized;
16588
+ normalized = getNormalizedAbsolutePath(path5, "");
16589
+ return normalized && hasTrailingDirectorySeparator(path5) ? ensureTrailingDirectorySeparator(normalized) : normalized;
16590
16590
  }
16591
- function simpleNormalizePath(path4) {
16592
- if (!relativePathSegmentRegExp.test(path4)) {
16593
- return path4;
16591
+ function simpleNormalizePath(path5) {
16592
+ if (!relativePathSegmentRegExp.test(path5)) {
16593
+ return path5;
16594
16594
  }
16595
- let simplified = path4.replace(/\/\.\//g, "/");
16595
+ let simplified = path5.replace(/\/\.\//g, "/");
16596
16596
  if (simplified.startsWith("./")) {
16597
16597
  simplified = simplified.slice(2);
16598
16598
  }
16599
- if (simplified !== path4) {
16600
- path4 = simplified;
16601
- if (!relativePathSegmentRegExp.test(path4)) {
16602
- return path4;
16599
+ if (simplified !== path5) {
16600
+ path5 = simplified;
16601
+ if (!relativePathSegmentRegExp.test(path5)) {
16602
+ return path5;
16603
16603
  }
16604
16604
  }
16605
16605
  return void 0;
@@ -16615,31 +16615,31 @@ ${lanes.join("\n")}
16615
16615
  const nonCanonicalizedPath = isRootedDiskPath(fileName) ? normalizePath(fileName) : getNormalizedAbsolutePath(fileName, basePath);
16616
16616
  return getCanonicalFileName(nonCanonicalizedPath);
16617
16617
  }
16618
- function removeTrailingDirectorySeparator(path4) {
16619
- if (hasTrailingDirectorySeparator(path4)) {
16620
- return path4.substr(0, path4.length - 1);
16618
+ function removeTrailingDirectorySeparator(path5) {
16619
+ if (hasTrailingDirectorySeparator(path5)) {
16620
+ return path5.substr(0, path5.length - 1);
16621
16621
  }
16622
- return path4;
16622
+ return path5;
16623
16623
  }
16624
- function ensureTrailingDirectorySeparator(path4) {
16625
- if (!hasTrailingDirectorySeparator(path4)) {
16626
- return path4 + directorySeparator;
16624
+ function ensureTrailingDirectorySeparator(path5) {
16625
+ if (!hasTrailingDirectorySeparator(path5)) {
16626
+ return path5 + directorySeparator;
16627
16627
  }
16628
- return path4;
16628
+ return path5;
16629
16629
  }
16630
- function ensurePathIsNonModuleName(path4) {
16631
- return !pathIsAbsolute(path4) && !pathIsRelative(path4) ? "./" + path4 : path4;
16630
+ function ensurePathIsNonModuleName(path5) {
16631
+ return !pathIsAbsolute(path5) && !pathIsRelative(path5) ? "./" + path5 : path5;
16632
16632
  }
16633
- function changeAnyExtension(path4, ext, extensions, ignoreCase) {
16634
- const pathext = extensions !== void 0 && ignoreCase !== void 0 ? getAnyExtensionFromPath(path4, extensions, ignoreCase) : getAnyExtensionFromPath(path4);
16635
- return pathext ? path4.slice(0, path4.length - pathext.length) + (startsWith(ext, ".") ? ext : "." + ext) : path4;
16633
+ function changeAnyExtension(path5, ext, extensions, ignoreCase) {
16634
+ const pathext = extensions !== void 0 && ignoreCase !== void 0 ? getAnyExtensionFromPath(path5, extensions, ignoreCase) : getAnyExtensionFromPath(path5);
16635
+ return pathext ? path5.slice(0, path5.length - pathext.length) + (startsWith(ext, ".") ? ext : "." + ext) : path5;
16636
16636
  }
16637
- function changeFullExtension(path4, newExtension) {
16638
- const declarationExtension = getDeclarationFileExtension(path4);
16637
+ function changeFullExtension(path5, newExtension) {
16638
+ const declarationExtension = getDeclarationFileExtension(path5);
16639
16639
  if (declarationExtension) {
16640
- return path4.slice(0, path4.length - declarationExtension.length) + (startsWith(newExtension, ".") ? newExtension : "." + newExtension);
16640
+ return path5.slice(0, path5.length - declarationExtension.length) + (startsWith(newExtension, ".") ? newExtension : "." + newExtension);
16641
16641
  }
16642
- return changeAnyExtension(path4, newExtension);
16642
+ return changeAnyExtension(path5, newExtension);
16643
16643
  }
16644
16644
  var relativePathSegmentRegExp = /\/\/|(?:^|\/)\.\.?(?:$|\/)/;
16645
16645
  function comparePathsWorker(a, b, componentComparer) {
@@ -28092,8 +28092,8 @@ ${lanes.join("\n")}
28092
28092
  function getResolvedExternalModuleName(host, file, referenceFile) {
28093
28093
  return file.moduleName || getExternalModuleNameFromPath(host, file.fileName, referenceFile && referenceFile.fileName);
28094
28094
  }
28095
- function getCanonicalAbsolutePath(host, path4) {
28096
- return host.getCanonicalFileName(getNormalizedAbsolutePath(path4, host.getCurrentDirectory()));
28095
+ function getCanonicalAbsolutePath(host, path5) {
28096
+ return host.getCanonicalFileName(getNormalizedAbsolutePath(path5, host.getCurrentDirectory()));
28097
28097
  }
28098
28098
  function getExternalModuleNameFromDeclaration(host, resolver, declaration) {
28099
28099
  const file = resolver.getExternalModuleFileFromDeclaration(declaration);
@@ -28136,20 +28136,20 @@ ${lanes.join("\n")}
28136
28136
  }
28137
28137
  function getDeclarationEmitOutputFilePathWorker(fileName, options, host) {
28138
28138
  const outputDir = options.declarationDir || options.outDir;
28139
- const path4 = outputDir ? getSourceFilePathInNewDirWorker(fileName, outputDir, host.getCurrentDirectory(), host.getCommonSourceDirectory(), (f) => host.getCanonicalFileName(f)) : fileName;
28140
- const declarationExtension = getDeclarationEmitExtensionForPath(path4);
28141
- return removeFileExtension(path4) + declarationExtension;
28139
+ const path5 = outputDir ? getSourceFilePathInNewDirWorker(fileName, outputDir, host.getCurrentDirectory(), host.getCommonSourceDirectory(), (f) => host.getCanonicalFileName(f)) : fileName;
28140
+ const declarationExtension = getDeclarationEmitExtensionForPath(path5);
28141
+ return removeFileExtension(path5) + declarationExtension;
28142
28142
  }
28143
- function getDeclarationEmitExtensionForPath(path4) {
28144
- return fileExtensionIsOneOf(path4, [
28143
+ function getDeclarationEmitExtensionForPath(path5) {
28144
+ return fileExtensionIsOneOf(path5, [
28145
28145
  ".mjs",
28146
28146
  ".mts"
28147
28147
  /* Mts */
28148
- ]) ? ".d.mts" : fileExtensionIsOneOf(path4, [
28148
+ ]) ? ".d.mts" : fileExtensionIsOneOf(path5, [
28149
28149
  ".cjs",
28150
28150
  ".cts"
28151
28151
  /* Cts */
28152
- ]) ? ".d.cts" : fileExtensionIsOneOf(path4, [
28152
+ ]) ? ".d.cts" : fileExtensionIsOneOf(path5, [
28153
28153
  ".json"
28154
28154
  /* Json */
28155
28155
  ]) ? `.d.json.ts` : (
@@ -28157,8 +28157,8 @@ ${lanes.join("\n")}
28157
28157
  ".d.ts"
28158
28158
  );
28159
28159
  }
28160
- function getPossibleOriginalInputExtensionForExtension(path4) {
28161
- return fileExtensionIsOneOf(path4, [
28160
+ function getPossibleOriginalInputExtensionForExtension(path5) {
28161
+ return fileExtensionIsOneOf(path5, [
28162
28162
  ".d.mts",
28163
28163
  ".mjs",
28164
28164
  ".mts"
@@ -28167,7 +28167,7 @@ ${lanes.join("\n")}
28167
28167
  ".mts",
28168
28168
  ".mjs"
28169
28169
  /* Mjs */
28170
- ] : fileExtensionIsOneOf(path4, [
28170
+ ] : fileExtensionIsOneOf(path5, [
28171
28171
  ".d.cts",
28172
28172
  ".cjs",
28173
28173
  ".cts"
@@ -28176,7 +28176,7 @@ ${lanes.join("\n")}
28176
28176
  ".cts",
28177
28177
  ".cjs"
28178
28178
  /* Cjs */
28179
- ] : fileExtensionIsOneOf(path4, [`.d.json.ts`]) ? [
28179
+ ] : fileExtensionIsOneOf(path5, [`.d.json.ts`]) ? [
28180
28180
  ".json"
28181
28181
  /* Json */
28182
28182
  ] : [
@@ -28261,12 +28261,12 @@ ${lanes.join("\n")}
28261
28261
  createDirectory(directoryPath);
28262
28262
  }
28263
28263
  }
28264
- function writeFileEnsuringDirectories(path4, data, writeByteOrderMark, writeFile2, createDirectory, directoryExists) {
28264
+ function writeFileEnsuringDirectories(path5, data, writeByteOrderMark, writeFile2, createDirectory, directoryExists) {
28265
28265
  try {
28266
- writeFile2(path4, data, writeByteOrderMark);
28266
+ writeFile2(path5, data, writeByteOrderMark);
28267
28267
  } catch {
28268
- ensureDirectoriesExist(getDirectoryPath(normalizePath(path4)), createDirectory, directoryExists);
28269
- writeFile2(path4, data, writeByteOrderMark);
28268
+ ensureDirectoriesExist(getDirectoryPath(normalizePath(path5)), createDirectory, directoryExists);
28269
+ writeFile2(path5, data, writeByteOrderMark);
28270
28270
  }
28271
28271
  }
28272
28272
  function getLineOfLocalPosition(sourceFile, pos) {
@@ -28966,20 +28966,20 @@ ${lanes.join("\n")}
28966
28966
  }
28967
28967
  return getStringFromExpandedCharCodes(expandedCharCodes);
28968
28968
  }
28969
- function readJsonOrUndefined(path4, hostOrText) {
28970
- const jsonText = isString(hostOrText) ? hostOrText : hostOrText.readFile(path4);
28969
+ function readJsonOrUndefined(path5, hostOrText) {
28970
+ const jsonText = isString(hostOrText) ? hostOrText : hostOrText.readFile(path5);
28971
28971
  if (!jsonText) return void 0;
28972
28972
  let result = tryParseJson(jsonText);
28973
28973
  if (result === void 0) {
28974
- const looseResult = parseConfigFileTextToJson(path4, jsonText);
28974
+ const looseResult = parseConfigFileTextToJson(path5, jsonText);
28975
28975
  if (!looseResult.error) {
28976
28976
  result = looseResult.config;
28977
28977
  }
28978
28978
  }
28979
28979
  return result;
28980
28980
  }
28981
- function readJson(path4, host) {
28982
- return readJsonOrUndefined(path4, host) || {};
28981
+ function readJson(path5, host) {
28982
+ return readJsonOrUndefined(path5, host) || {};
28983
28983
  }
28984
28984
  function tryParseJson(text4) {
28985
28985
  try {
@@ -30129,7 +30129,7 @@ ${lanes.join("\n")}
30129
30129
  getSymlinkedFiles: () => symlinkedFiles,
30130
30130
  getSymlinkedDirectories: () => symlinkedDirectories,
30131
30131
  getSymlinkedDirectoriesByRealpath: () => symlinkedDirectoriesByRealpath,
30132
- setSymlinkedFile: (path4, real) => (symlinkedFiles || (symlinkedFiles = /* @__PURE__ */ new Map())).set(path4, real),
30132
+ setSymlinkedFile: (path5, real) => (symlinkedFiles || (symlinkedFiles = /* @__PURE__ */ new Map())).set(path5, real),
30133
30133
  setSymlinkedDirectory: (symlink, real) => {
30134
30134
  let symlinkPath = toPath(symlink, cwd, getCanonicalFileName);
30135
30135
  if (!containsIgnoredPath(symlinkPath)) {
@@ -30189,8 +30189,8 @@ ${lanes.join("\n")}
30189
30189
  function stripLeadingDirectorySeparator(s) {
30190
30190
  return isAnyDirectorySeparator(s.charCodeAt(0)) ? s.slice(1) : void 0;
30191
30191
  }
30192
- function tryRemoveDirectoryPrefix(path4, dirPath, getCanonicalFileName) {
30193
- const withoutPrefix = tryRemovePrefix(path4, dirPath, getCanonicalFileName);
30192
+ function tryRemoveDirectoryPrefix(path5, dirPath, getCanonicalFileName) {
30193
+ const withoutPrefix = tryRemovePrefix(path5, dirPath, getCanonicalFileName);
30194
30194
  return withoutPrefix === void 0 ? void 0 : stripLeadingDirectorySeparator(withoutPrefix);
30195
30195
  }
30196
30196
  var reservedCharacterPattern = /[^\w\s/]/g;
@@ -30316,25 +30316,25 @@ ${lanes.join("\n")}
30316
30316
  function replaceWildcardCharacter(match2, singleAsteriskRegexFragment) {
30317
30317
  return match2 === "*" ? singleAsteriskRegexFragment : match2 === "?" ? "[^/]" : "\\" + match2;
30318
30318
  }
30319
- function getFileMatcherPatterns(path4, excludes, includes, useCaseSensitiveFileNames2, currentDirectory) {
30320
- path4 = normalizePath(path4);
30319
+ function getFileMatcherPatterns(path5, excludes, includes, useCaseSensitiveFileNames2, currentDirectory) {
30320
+ path5 = normalizePath(path5);
30321
30321
  currentDirectory = normalizePath(currentDirectory);
30322
- const absolutePath = combinePaths(currentDirectory, path4);
30322
+ const absolutePath = combinePaths(currentDirectory, path5);
30323
30323
  return {
30324
30324
  includeFilePatterns: map(getRegularExpressionsForWildcards(includes, absolutePath, "files"), (pattern) => `^${pattern}$`),
30325
30325
  includeFilePattern: getRegularExpressionForWildcard(includes, absolutePath, "files"),
30326
30326
  includeDirectoryPattern: getRegularExpressionForWildcard(includes, absolutePath, "directories"),
30327
30327
  excludePattern: getRegularExpressionForWildcard(excludes, absolutePath, "exclude"),
30328
- basePaths: getBasePaths(path4, includes, useCaseSensitiveFileNames2)
30328
+ basePaths: getBasePaths(path5, includes, useCaseSensitiveFileNames2)
30329
30329
  };
30330
30330
  }
30331
30331
  function getRegexFromPattern(pattern, useCaseSensitiveFileNames2) {
30332
30332
  return new RegExp(pattern, useCaseSensitiveFileNames2 ? "" : "i");
30333
30333
  }
30334
- function matchFiles(path4, extensions, excludes, includes, useCaseSensitiveFileNames2, currentDirectory, depth, getFileSystemEntries, realpath) {
30335
- path4 = normalizePath(path4);
30334
+ function matchFiles(path5, extensions, excludes, includes, useCaseSensitiveFileNames2, currentDirectory, depth, getFileSystemEntries, realpath) {
30335
+ path5 = normalizePath(path5);
30336
30336
  currentDirectory = normalizePath(currentDirectory);
30337
- const patterns = getFileMatcherPatterns(path4, excludes, includes, useCaseSensitiveFileNames2, currentDirectory);
30337
+ const patterns = getFileMatcherPatterns(path5, excludes, includes, useCaseSensitiveFileNames2, currentDirectory);
30338
30338
  const includeFileRegexes = patterns.includeFilePatterns && patterns.includeFilePatterns.map((pattern) => getRegexFromPattern(pattern, useCaseSensitiveFileNames2));
30339
30339
  const includeDirectoryRegex = patterns.includeDirectoryPattern && getRegexFromPattern(patterns.includeDirectoryPattern, useCaseSensitiveFileNames2);
30340
30340
  const excludeRegex = patterns.excludePattern && getRegexFromPattern(patterns.excludePattern, useCaseSensitiveFileNames2);
@@ -30379,17 +30379,17 @@ ${lanes.join("\n")}
30379
30379
  }
30380
30380
  }
30381
30381
  }
30382
- function getBasePaths(path4, includes, useCaseSensitiveFileNames2) {
30383
- const basePaths = [path4];
30382
+ function getBasePaths(path5, includes, useCaseSensitiveFileNames2) {
30383
+ const basePaths = [path5];
30384
30384
  if (includes) {
30385
30385
  const includeBasePaths = [];
30386
30386
  for (const include of includes) {
30387
- const absolute = isRootedDiskPath(include) ? include : normalizePath(combinePaths(path4, include));
30387
+ const absolute = isRootedDiskPath(include) ? include : normalizePath(combinePaths(path5, include));
30388
30388
  includeBasePaths.push(getIncludeBasePath(absolute));
30389
30389
  }
30390
30390
  includeBasePaths.sort(getStringComparer(!useCaseSensitiveFileNames2));
30391
30391
  for (const includeBasePath of includeBasePaths) {
30392
- if (every(basePaths, (basePath) => !containsPath(basePath, includeBasePath, path4, !useCaseSensitiveFileNames2))) {
30392
+ if (every(basePaths, (basePath) => !containsPath(basePath, includeBasePath, path5, !useCaseSensitiveFileNames2))) {
30393
30393
  basePaths.push(includeBasePath);
30394
30394
  }
30395
30395
  }
@@ -30653,24 +30653,24 @@ ${lanes.join("\n")}
30653
30653
  ".json"
30654
30654
  /* Json */
30655
30655
  ];
30656
- function removeFileExtension(path4) {
30656
+ function removeFileExtension(path5) {
30657
30657
  for (const ext of extensionsToRemove) {
30658
- const extensionless = tryRemoveExtension(path4, ext);
30658
+ const extensionless = tryRemoveExtension(path5, ext);
30659
30659
  if (extensionless !== void 0) {
30660
30660
  return extensionless;
30661
30661
  }
30662
30662
  }
30663
- return path4;
30663
+ return path5;
30664
30664
  }
30665
- function tryRemoveExtension(path4, extension) {
30666
- return fileExtensionIs(path4, extension) ? removeExtension(path4, extension) : void 0;
30665
+ function tryRemoveExtension(path5, extension) {
30666
+ return fileExtensionIs(path5, extension) ? removeExtension(path5, extension) : void 0;
30667
30667
  }
30668
- function removeExtension(path4, extension) {
30669
- return path4.substring(0, path4.length - extension.length);
30668
+ function removeExtension(path5, extension) {
30669
+ return path5.substring(0, path5.length - extension.length);
30670
30670
  }
30671
- function changeExtension(path4, newExtension) {
30671
+ function changeExtension(path5, newExtension) {
30672
30672
  return changeAnyExtension(
30673
- path4,
30673
+ path5,
30674
30674
  newExtension,
30675
30675
  extensionsToRemove,
30676
30676
  /*ignoreCase*/
@@ -30696,8 +30696,8 @@ ${lanes.join("\n")}
30696
30696
  let matchableStringSet;
30697
30697
  let patterns;
30698
30698
  const pathList = getOwnKeys(paths);
30699
- for (const path4 of pathList) {
30700
- const patternOrStr = tryParsePattern(path4);
30699
+ for (const path5 of pathList) {
30700
+ const patternOrStr = tryParsePattern(path5);
30701
30701
  if (patternOrStr === void 0) {
30702
30702
  continue;
30703
30703
  } else if (typeof patternOrStr === "string") {
@@ -30724,15 +30724,15 @@ ${lanes.join("\n")}
30724
30724
  function resolutionExtensionIsTSOrJson(ext) {
30725
30725
  return extensionIsTS(ext) || ext === ".json";
30726
30726
  }
30727
- function extensionFromPath(path4) {
30728
- const ext = tryGetExtensionFromPath2(path4);
30729
- return ext !== void 0 ? ext : Debug.fail(`File ${path4} has unknown extension.`);
30727
+ function extensionFromPath(path5) {
30728
+ const ext = tryGetExtensionFromPath2(path5);
30729
+ return ext !== void 0 ? ext : Debug.fail(`File ${path5} has unknown extension.`);
30730
30730
  }
30731
- function isAnySupportedFileExtension(path4) {
30732
- return tryGetExtensionFromPath2(path4) !== void 0;
30731
+ function isAnySupportedFileExtension(path5) {
30732
+ return tryGetExtensionFromPath2(path5) !== void 0;
30733
30733
  }
30734
- function tryGetExtensionFromPath2(path4) {
30735
- return find(extensionsToRemove, (e) => fileExtensionIs(path4, e));
30734
+ function tryGetExtensionFromPath2(path5) {
30735
+ return find(extensionsToRemove, (e) => fileExtensionIs(path5, e));
30736
30736
  }
30737
30737
  function isCheckJsEnabledForFile(sourceFile, compilerOptions) {
30738
30738
  return sourceFile.checkJsDirective ? sourceFile.checkJsDirective.enabled : compilerOptions.checkJs;
@@ -31041,8 +31041,8 @@ ${lanes.join("\n")}
31041
31041
  return false;
31042
31042
  }
31043
31043
  }
31044
- function containsIgnoredPath(path4) {
31045
- return some(ignoredPaths, (p9) => path4.includes(p9));
31044
+ function containsIgnoredPath(path5) {
31045
+ return some(ignoredPaths, (p9) => path5.includes(p9));
31046
31046
  }
31047
31047
  function getContainingNodeArray(node) {
31048
31048
  if (!node.parent) return void 0;
@@ -50850,7 +50850,7 @@ ${lanes.join("\n")}
50850
50850
  const typeReferenceDirectives = context.typeReferenceDirectives;
50851
50851
  const libReferenceDirectives = context.libReferenceDirectives;
50852
50852
  forEach(toArray(entryOrList), (arg) => {
50853
- const { types, lib, path: path4, ["resolution-mode"]: res, preserve: _preserve } = arg.arguments;
50853
+ const { types, lib, path: path5, ["resolution-mode"]: res, preserve: _preserve } = arg.arguments;
50854
50854
  const preserve = _preserve === "true" ? true : void 0;
50855
50855
  if (arg.arguments["no-default-lib"] === "true") {
50856
50856
  context.hasNoDefaultLib = true;
@@ -50859,8 +50859,8 @@ ${lanes.join("\n")}
50859
50859
  typeReferenceDirectives.push({ pos: types.pos, end: types.end, fileName: types.value, ...parsed ? { resolutionMode: parsed } : {}, ...preserve ? { preserve } : {} });
50860
50860
  } else if (lib) {
50861
50861
  libReferenceDirectives.push({ pos: lib.pos, end: lib.end, fileName: lib.value, ...preserve ? { preserve } : {} });
50862
- } else if (path4) {
50863
- referencedFiles.push({ pos: path4.pos, end: path4.end, fileName: path4.value, ...preserve ? { preserve } : {} });
50862
+ } else if (path5) {
50863
+ referencedFiles.push({ pos: path5.pos, end: path5.end, fileName: path5.value, ...preserve ? { preserve } : {} });
50864
50864
  } else {
50865
50865
  reportDiagnostic(arg.range.pos, arg.range.end - arg.range.pos, Diagnostics.Invalid_reference_directive_syntax);
50866
50866
  }
@@ -53289,9 +53289,9 @@ ${lanes.join("\n")}
53289
53289
  if (specs[0] === defaultIncludeSpec) return void 0;
53290
53290
  return specs;
53291
53291
  }
53292
- function matchesSpecs(path4, includeSpecs, excludeSpecs, host) {
53292
+ function matchesSpecs(path5, includeSpecs, excludeSpecs, host) {
53293
53293
  if (!includeSpecs) return returnTrue;
53294
- const patterns = getFileMatcherPatterns(path4, excludeSpecs, includeSpecs, host.useCaseSensitiveFileNames, host.getCurrentDirectory());
53294
+ const patterns = getFileMatcherPatterns(path5, excludeSpecs, includeSpecs, host.useCaseSensitiveFileNames, host.getCurrentDirectory());
53295
53295
  const excludeRe = patterns.excludePattern && getRegexFromPattern(patterns.excludePattern, host.useCaseSensitiveFileNames);
53296
53296
  const includeRe = patterns.includeFilePattern && getRegexFromPattern(patterns.includeFilePattern, host.useCaseSensitiveFileNames);
53297
53297
  if (includeRe) {
@@ -53936,9 +53936,9 @@ ${lanes.join("\n")}
53936
53936
  const setPropertyInResultIfNotUndefined = (propertyName) => {
53937
53937
  if (ownConfig.raw[propertyName]) return;
53938
53938
  if (extendsRaw[propertyName]) {
53939
- result[propertyName] = map(extendsRaw[propertyName], (path4) => startsWithConfigDirTemplate(path4) || isRootedDiskPath(path4) ? path4 : combinePaths(
53939
+ result[propertyName] = map(extendsRaw[propertyName], (path5) => startsWithConfigDirTemplate(path5) || isRootedDiskPath(path5) ? path5 : combinePaths(
53940
53940
  relativeDifference || (relativeDifference = convertToRelativePath(getDirectoryPath(extendedConfigPath), basePath, createGetCanonicalFileName(host.useCaseSensitiveFileNames))),
53941
- path4
53941
+ path5
53942
53942
  ));
53943
53943
  }
53944
53944
  };
@@ -54092,11 +54092,11 @@ ${lanes.join("\n")}
54092
54092
  return void 0;
54093
54093
  }
54094
54094
  function getExtendedConfig(sourceFile, extendedConfigPath, host, resolutionStack, errors, extendedConfigCache, result) {
54095
- const path4 = host.useCaseSensitiveFileNames ? extendedConfigPath : toFileNameLowerCase(extendedConfigPath);
54095
+ const path5 = host.useCaseSensitiveFileNames ? extendedConfigPath : toFileNameLowerCase(extendedConfigPath);
54096
54096
  let value;
54097
54097
  let extendedResult;
54098
54098
  let extendedConfig;
54099
- if (extendedConfigCache && (value = extendedConfigCache.get(path4))) {
54099
+ if (extendedConfigCache && (value = extendedConfigCache.get(path5))) {
54100
54100
  ({ extendedResult, extendedConfig } = value);
54101
54101
  } else {
54102
54102
  extendedResult = readJsonConfigFile(extendedConfigPath, (path22) => host.readFile(path22));
@@ -54114,7 +54114,7 @@ ${lanes.join("\n")}
54114
54114
  );
54115
54115
  }
54116
54116
  if (extendedConfigCache) {
54117
- extendedConfigCache.set(path4, { extendedResult, extendedConfig });
54117
+ extendedConfigCache.set(path5, { extendedResult, extendedConfig });
54118
54118
  }
54119
54119
  }
54120
54120
  if (sourceFile) {
@@ -54382,24 +54382,24 @@ ${lanes.join("\n")}
54382
54382
  }
54383
54383
  const match2 = getWildcardDirectoryFromSpec(spec, useCaseSensitiveFileNames2);
54384
54384
  if (match2) {
54385
- const { key, path: path4, flags } = match2;
54385
+ const { key, path: path5, flags } = match2;
54386
54386
  const existingPath = wildCardKeyToPath.get(key);
54387
54387
  const existingFlags = existingPath !== void 0 ? wildcardDirectories[existingPath] : void 0;
54388
54388
  if (existingFlags === void 0 || existingFlags < flags) {
54389
- wildcardDirectories[existingPath !== void 0 ? existingPath : path4] = flags;
54390
- if (existingPath === void 0) wildCardKeyToPath.set(key, path4);
54389
+ wildcardDirectories[existingPath !== void 0 ? existingPath : path5] = flags;
54390
+ if (existingPath === void 0) wildCardKeyToPath.set(key, path5);
54391
54391
  if (flags === 1) {
54392
54392
  recursiveKeys.push(key);
54393
54393
  }
54394
54394
  }
54395
54395
  }
54396
54396
  }
54397
- for (const path4 in wildcardDirectories) {
54398
- if (hasProperty(wildcardDirectories, path4)) {
54397
+ for (const path5 in wildcardDirectories) {
54398
+ if (hasProperty(wildcardDirectories, path5)) {
54399
54399
  for (const recursiveKey of recursiveKeys) {
54400
- const key = toCanonicalKey(path4, useCaseSensitiveFileNames2);
54400
+ const key = toCanonicalKey(path5, useCaseSensitiveFileNames2);
54401
54401
  if (key !== recursiveKey && containsPath(recursiveKey, key, basePath, !useCaseSensitiveFileNames2)) {
54402
- delete wildcardDirectories[path4];
54402
+ delete wildcardDirectories[path5];
54403
54403
  }
54404
54404
  }
54405
54405
  }
@@ -54407,8 +54407,8 @@ ${lanes.join("\n")}
54407
54407
  }
54408
54408
  return wildcardDirectories;
54409
54409
  }
54410
- function toCanonicalKey(path4, useCaseSensitiveFileNames2) {
54411
- return useCaseSensitiveFileNames2 ? path4 : toFileNameLowerCase(path4);
54410
+ function toCanonicalKey(path5, useCaseSensitiveFileNames2) {
54411
+ return useCaseSensitiveFileNames2 ? path5 : toFileNameLowerCase(path5);
54412
54412
  }
54413
54413
  function getWildcardDirectoryFromSpec(spec, useCaseSensitiveFileNames2) {
54414
54414
  const match2 = wildcardDirectoryPattern.exec(spec);
@@ -54424,10 +54424,10 @@ ${lanes.join("\n")}
54424
54424
  };
54425
54425
  }
54426
54426
  if (isImplicitGlob(spec.substring(spec.lastIndexOf(directorySeparator) + 1))) {
54427
- const path4 = removeTrailingDirectorySeparator(spec);
54427
+ const path5 = removeTrailingDirectorySeparator(spec);
54428
54428
  return {
54429
- key: toCanonicalKey(path4, useCaseSensitiveFileNames2),
54430
- path: path4,
54429
+ key: toCanonicalKey(path5, useCaseSensitiveFileNames2),
54430
+ path: path5,
54431
54431
  flags: 1
54432
54432
  /* Recursive */
54433
54433
  };
@@ -54666,11 +54666,11 @@ ${lanes.join("\n")}
54666
54666
  }
54667
54667
  return;
54668
54668
  }
54669
- const path4 = normalizePath(combinePaths(baseDirectory, fileName));
54669
+ const path5 = normalizePath(combinePaths(baseDirectory, fileName));
54670
54670
  if (state.traceEnabled) {
54671
- trace2(state.host, Diagnostics.package_json_has_0_field_1_that_references_2, fieldName, fileName, path4);
54671
+ trace2(state.host, Diagnostics.package_json_has_0_field_1_that_references_2, fieldName, fileName, path5);
54672
54672
  }
54673
- return path4;
54673
+ return path5;
54674
54674
  }
54675
54675
  function readPackageJsonTypesFields(jsonContent, baseDirectory, state) {
54676
54676
  return readPackageJsonPathField(jsonContent, "typings", baseDirectory, state) || readPackageJsonPathField(jsonContent, "types", baseDirectory, state);
@@ -55184,13 +55184,13 @@ ${lanes.join("\n")}
55184
55184
  directoryToModuleNameMap.update(options2);
55185
55185
  }
55186
55186
  function getOrCreateCacheForDirectory(directoryName, redirectedReference) {
55187
- const path4 = toPath(directoryName, currentDirectory, getCanonicalFileName);
55188
- return getOrCreateCache(directoryToModuleNameMap, redirectedReference, path4, () => createModeAwareCache());
55187
+ const path5 = toPath(directoryName, currentDirectory, getCanonicalFileName);
55188
+ return getOrCreateCache(directoryToModuleNameMap, redirectedReference, path5, () => createModeAwareCache());
55189
55189
  }
55190
55190
  function getFromDirectoryCache(name, mode, directoryName, redirectedReference) {
55191
55191
  var _a, _b;
55192
- const path4 = toPath(directoryName, currentDirectory, getCanonicalFileName);
55193
- return (_b = (_a = directoryToModuleNameMap.getMapOfCacheRedirects(redirectedReference)) == null ? void 0 : _a.get(path4)) == null ? void 0 : _b.get(name, mode);
55192
+ const path5 = toPath(directoryName, currentDirectory, getCanonicalFileName);
55193
+ return (_b = (_a = directoryToModuleNameMap.getMapOfCacheRedirects(redirectedReference)) == null ? void 0 : _a.get(path5)) == null ? void 0 : _b.get(name, mode);
55194
55194
  }
55195
55195
  }
55196
55196
  function createModeAwareCacheKey(specifier, mode) {
@@ -55267,14 +55267,14 @@ ${lanes.join("\n")}
55267
55267
  return directoryPathMap.get(toPath(directory, currentDirectory, getCanonicalFileName));
55268
55268
  }
55269
55269
  function set(directory, result) {
55270
- const path4 = toPath(directory, currentDirectory, getCanonicalFileName);
55271
- if (directoryPathMap.has(path4)) {
55270
+ const path5 = toPath(directory, currentDirectory, getCanonicalFileName);
55271
+ if (directoryPathMap.has(path5)) {
55272
55272
  return;
55273
55273
  }
55274
- directoryPathMap.set(path4, result);
55274
+ directoryPathMap.set(path5, result);
55275
55275
  const resolvedFileName = getResolvedFileName(result);
55276
- const commonPrefix = resolvedFileName && getCommonPrefix(path4, resolvedFileName);
55277
- let current = path4;
55276
+ const commonPrefix = resolvedFileName && getCommonPrefix(path5, resolvedFileName);
55277
+ let current = path5;
55278
55278
  while (current !== commonPrefix) {
55279
55279
  const parent2 = getDirectoryPath(current);
55280
55280
  if (parent2 === current || directoryPathMap.has(parent2)) {
@@ -55838,16 +55838,16 @@ ${lanes.join("\n")}
55838
55838
  const combined = combinePaths(containingDirectory, moduleName);
55839
55839
  const parts = getPathComponents(combined);
55840
55840
  const lastPart = lastOrUndefined(parts);
55841
- const path4 = lastPart === "." || lastPart === ".." ? ensureTrailingDirectorySeparator(normalizePath(combined)) : normalizePath(combined);
55842
- return { path: path4, parts };
55841
+ const path5 = lastPart === "." || lastPart === ".." ? ensureTrailingDirectorySeparator(normalizePath(combined)) : normalizePath(combined);
55842
+ return { path: path5, parts };
55843
55843
  }
55844
- function realPath(path4, host, traceEnabled) {
55844
+ function realPath(path5, host, traceEnabled) {
55845
55845
  if (!host.realpath) {
55846
- return path4;
55846
+ return path5;
55847
55847
  }
55848
- const real = normalizePath(host.realpath(path4));
55848
+ const real = normalizePath(host.realpath(path5));
55849
55849
  if (traceEnabled) {
55850
- trace2(host, Diagnostics.Resolving_real_path_for_0_result_1, path4, real);
55850
+ trace2(host, Diagnostics.Resolving_real_path_for_0_result_1, path5, real);
55851
55851
  }
55852
55852
  return real;
55853
55853
  }
@@ -55892,25 +55892,25 @@ ${lanes.join("\n")}
55892
55892
  return void 0;
55893
55893
  }
55894
55894
  var nodeModulesPathPart = "/node_modules/";
55895
- function pathContainsNodeModules(path4) {
55896
- return path4.includes(nodeModulesPathPart);
55895
+ function pathContainsNodeModules(path5) {
55896
+ return path5.includes(nodeModulesPathPart);
55897
55897
  }
55898
55898
  function parseNodeModuleFromPath(resolved, isFolder) {
55899
- const path4 = normalizePath(resolved);
55900
- const idx = path4.lastIndexOf(nodeModulesPathPart);
55899
+ const path5 = normalizePath(resolved);
55900
+ const idx = path5.lastIndexOf(nodeModulesPathPart);
55901
55901
  if (idx === -1) {
55902
55902
  return void 0;
55903
55903
  }
55904
55904
  const indexAfterNodeModules = idx + nodeModulesPathPart.length;
55905
- let indexAfterPackageName = moveToNextDirectorySeparatorIfAvailable(path4, indexAfterNodeModules, isFolder);
55906
- if (path4.charCodeAt(indexAfterNodeModules) === 64) {
55907
- indexAfterPackageName = moveToNextDirectorySeparatorIfAvailable(path4, indexAfterPackageName, isFolder);
55905
+ let indexAfterPackageName = moveToNextDirectorySeparatorIfAvailable(path5, indexAfterNodeModules, isFolder);
55906
+ if (path5.charCodeAt(indexAfterNodeModules) === 64) {
55907
+ indexAfterPackageName = moveToNextDirectorySeparatorIfAvailable(path5, indexAfterPackageName, isFolder);
55908
55908
  }
55909
- return path4.slice(0, indexAfterPackageName);
55909
+ return path5.slice(0, indexAfterPackageName);
55910
55910
  }
55911
- function moveToNextDirectorySeparatorIfAvailable(path4, prevSeparatorIndex, isFolder) {
55912
- const nextSeparatorIndex = path4.indexOf(directorySeparator, prevSeparatorIndex + 1);
55913
- return nextSeparatorIndex === -1 ? isFolder ? path4.length : prevSeparatorIndex : nextSeparatorIndex;
55911
+ function moveToNextDirectorySeparatorIfAvailable(path5, prevSeparatorIndex, isFolder) {
55912
+ const nextSeparatorIndex = path5.indexOf(directorySeparator, prevSeparatorIndex + 1);
55913
+ return nextSeparatorIndex === -1 ? isFolder ? path5.length : prevSeparatorIndex : nextSeparatorIndex;
55914
55914
  }
55915
55915
  function loadModuleFromFileNoPackageId(extensions, candidate, onlyRecordFailures, state) {
55916
55916
  return noPackageId(loadModuleFromFile(extensions, candidate, onlyRecordFailures, state));
@@ -56052,8 +56052,8 @@ ${lanes.join("\n")}
56052
56052
  return extensions & 4 && !isDeclarationFileName(candidate + originalExtension) && tryExtension(`.d${originalExtension}.ts`) || void 0;
56053
56053
  }
56054
56054
  function tryExtension(ext, resolvedUsingTsExtension) {
56055
- const path4 = tryFile(candidate + ext, onlyRecordFailures, state);
56056
- return path4 === void 0 ? void 0 : { path: path4, ext, resolvedUsingTsExtension: !state.candidateIsFromPackageJsonField && resolvedUsingTsExtension };
56055
+ const path5 = tryFile(candidate + ext, onlyRecordFailures, state);
56056
+ return path5 === void 0 ? void 0 : { path: path5, ext, resolvedUsingTsExtension: !state.candidateIsFromPackageJsonField && resolvedUsingTsExtension };
56057
56057
  }
56058
56058
  }
56059
56059
  function tryFile(fileName, onlyRecordFailures, state) {
@@ -56749,10 +56749,10 @@ ${lanes.join("\n")}
56749
56749
  /*value*/
56750
56750
  void 0
56751
56751
  );
56752
- function toAbsolutePath(path4) {
56752
+ function toAbsolutePath(path5) {
56753
56753
  var _a2, _b2;
56754
- if (path4 === void 0) return path4;
56755
- return getNormalizedAbsolutePath(path4, (_b2 = (_a2 = state.host).getCurrentDirectory) == null ? void 0 : _b2.call(_a2));
56754
+ if (path5 === void 0) return path5;
56755
+ return getNormalizedAbsolutePath(path5, (_b2 = (_a2 = state.host).getCurrentDirectory) == null ? void 0 : _b2.call(_a2));
56756
56756
  }
56757
56757
  function combineDirectoryPath(root, dir) {
56758
56758
  return ensureTrailingDirectorySeparator(combinePaths(root, dir));
@@ -57003,10 +57003,10 @@ ${lanes.join("\n")}
57003
57003
  trace2(state.host, Diagnostics.Module_name_0_matched_pattern_1, moduleName, matchedPatternText);
57004
57004
  }
57005
57005
  const resolved = forEach(paths[matchedPatternText], (subst) => {
57006
- const path4 = matchedStar ? replaceFirstStar(subst, matchedStar) : subst;
57007
- const candidate = normalizePath(combinePaths(baseDirectory, path4));
57006
+ const path5 = matchedStar ? replaceFirstStar(subst, matchedStar) : subst;
57007
+ const candidate = normalizePath(combinePaths(baseDirectory, path5));
57008
57008
  if (state.traceEnabled) {
57009
- trace2(state.host, Diagnostics.Trying_substitution_0_candidate_module_location_Colon_1, subst, path4);
57009
+ trace2(state.host, Diagnostics.Trying_substitution_0_candidate_module_location_Colon_1, subst, path5);
57010
57010
  }
57011
57011
  const extension = tryGetExtensionFromPath2(subst);
57012
57012
  if (extension !== void 0) {
@@ -61159,10 +61159,10 @@ ${lanes.join("\n")}
61159
61159
  if (a === void 0 || b === void 0) return false;
61160
61160
  return comparePaths(a, b, ignoreCase) === 0;
61161
61161
  }
61162
- function countPathComponents(path4) {
61162
+ function countPathComponents(path5) {
61163
61163
  let count18 = 0;
61164
- for (let i = startsWith(path4, "./") ? 2 : 0; i < path4.length; i++) {
61165
- if (path4.charCodeAt(i) === 47) count18++;
61164
+ for (let i = startsWith(path5, "./") ? 2 : 0; i < path5.length; i++) {
61165
+ if (path5.charCodeAt(i) === 47) count18++;
61166
61166
  }
61167
61167
  return count18;
61168
61168
  }
@@ -61279,9 +61279,9 @@ ${lanes.join("\n")}
61279
61279
  host,
61280
61280
  /*preferSymlinks*/
61281
61281
  true,
61282
- (path4, isRedirect) => {
61283
- const isInNodeModules = pathContainsNodeModules(path4);
61284
- allFileNames.set(path4, { path: info.getCanonicalFileName(path4), isRedirect, isInNodeModules });
61282
+ (path5, isRedirect) => {
61283
+ const isInNodeModules = pathContainsNodeModules(path5);
61284
+ allFileNames.set(path5, { path: info.getCanonicalFileName(path5), isRedirect, isInNodeModules });
61285
61285
  importedFileFromNodeModules = importedFileFromNodeModules || isInNodeModules;
61286
61286
  }
61287
61287
  );
@@ -61289,8 +61289,8 @@ ${lanes.join("\n")}
61289
61289
  for (let directory = info.canonicalSourceDirectory; allFileNames.size !== 0; ) {
61290
61290
  const directoryStart = ensureTrailingDirectorySeparator(directory);
61291
61291
  let pathsInDirectory;
61292
- allFileNames.forEach(({ path: path4, isRedirect, isInNodeModules }, fileName) => {
61293
- if (startsWith(path4, directoryStart)) {
61292
+ allFileNames.forEach(({ path: path5, isRedirect, isInNodeModules }, fileName) => {
61293
+ if (startsWith(path5, directoryStart)) {
61294
61294
  (pathsInDirectory || (pathsInDirectory = [])).push({ path: fileName, isRedirect, isInNodeModules });
61295
61295
  allFileNames.delete(fileName);
61296
61296
  }
@@ -61593,17 +61593,17 @@ ${lanes.join("\n")}
61593
61593
  }
61594
61594
  return processEnding(shortest, allowedEndings, compilerOptions);
61595
61595
  }
61596
- function tryGetModuleNameAsNodeModule({ path: path4, isRedirect }, { getCanonicalFileName, canonicalSourceDirectory }, importingSourceFile, host, options, userPreferences, packageNameOnly, overrideMode) {
61596
+ function tryGetModuleNameAsNodeModule({ path: path5, isRedirect }, { getCanonicalFileName, canonicalSourceDirectory }, importingSourceFile, host, options, userPreferences, packageNameOnly, overrideMode) {
61597
61597
  if (!host.fileExists || !host.readFile) {
61598
61598
  return void 0;
61599
61599
  }
61600
- const parts = getNodeModulePathParts(path4);
61600
+ const parts = getNodeModulePathParts(path5);
61601
61601
  if (!parts) {
61602
61602
  return void 0;
61603
61603
  }
61604
61604
  const preferences = getModuleSpecifierPreferences(userPreferences, host, options, importingSourceFile);
61605
61605
  const allowedEndings = preferences.getAllowedEndingsInPreferredOrder();
61606
- let moduleSpecifier = path4;
61606
+ let moduleSpecifier = path5;
61607
61607
  let isPackageRootPath = false;
61608
61608
  if (!packageNameOnly) {
61609
61609
  let packageRootIndex = parts.packageRootIndex;
@@ -61624,7 +61624,7 @@ ${lanes.join("\n")}
61624
61624
  break;
61625
61625
  }
61626
61626
  if (!moduleFileName) moduleFileName = moduleFileToTry;
61627
- packageRootIndex = path4.indexOf(directorySeparator, packageRootIndex + 1);
61627
+ packageRootIndex = path5.indexOf(directorySeparator, packageRootIndex + 1);
61628
61628
  if (packageRootIndex === -1) {
61629
61629
  moduleSpecifier = processEnding(moduleFileName, allowedEndings, options, host);
61630
61630
  break;
@@ -61644,9 +61644,9 @@ ${lanes.join("\n")}
61644
61644
  return getEmitModuleResolutionKind(options) === 1 && packageName === nodeModulesDirectoryName ? void 0 : packageName;
61645
61645
  function tryDirectoryWithPackageJson(packageRootIndex) {
61646
61646
  var _a, _b;
61647
- const packageRootPath = path4.substring(0, packageRootIndex);
61647
+ const packageRootPath = path5.substring(0, packageRootIndex);
61648
61648
  const packageJsonPath2 = combinePaths(packageRootPath, "package.json");
61649
- let moduleFileToTry = path4;
61649
+ let moduleFileToTry = path5;
61650
61650
  let maybeBlockedByTypesVersions = false;
61651
61651
  const cachedPackageJson = (_b = (_a = host.getPackageJsonInfoCache) == null ? void 0 : _a.call(host)) == null ? void 0 : _b.getPackageJsonInfo(packageJsonPath2);
61652
61652
  if (isPackageJsonInfo(cachedPackageJson) || cachedPackageJson === void 0 && host.fileExists(packageJsonPath2)) {
@@ -61659,7 +61659,7 @@ ${lanes.join("\n")}
61659
61659
  const fromExports = (packageJsonContent == null ? void 0 : packageJsonContent.exports) ? tryGetModuleNameFromExports(
61660
61660
  options,
61661
61661
  host,
61662
- path4,
61662
+ path5,
61663
61663
  packageRootPath,
61664
61664
  packageName2,
61665
61665
  packageJsonContent.exports,
@@ -61669,12 +61669,12 @@ ${lanes.join("\n")}
61669
61669
  return { ...fromExports, verbatimFromExports: true };
61670
61670
  }
61671
61671
  if (packageJsonContent == null ? void 0 : packageJsonContent.exports) {
61672
- return { moduleFileToTry: path4, blockedByExports: true };
61672
+ return { moduleFileToTry: path5, blockedByExports: true };
61673
61673
  }
61674
61674
  }
61675
61675
  const versionPaths = (packageJsonContent == null ? void 0 : packageJsonContent.typesVersions) ? getPackageJsonTypesVersionsPaths(packageJsonContent.typesVersions) : void 0;
61676
61676
  if (versionPaths) {
61677
- const subModuleName = path4.slice(packageRootPath.length + 1);
61677
+ const subModuleName = path5.slice(packageRootPath.length + 1);
61678
61678
  const fromPaths = tryGetModuleNameFromPaths(
61679
61679
  subModuleName,
61680
61680
  versionPaths.paths,
@@ -61709,7 +61709,7 @@ ${lanes.join("\n")}
61709
61709
  return { moduleFileToTry };
61710
61710
  }
61711
61711
  }
61712
- function tryGetAnyFileFromPath(host, path4) {
61712
+ function tryGetAnyFileFromPath(host, path5) {
61713
61713
  if (!host.fileExists) return;
61714
61714
  const extensions = flatten(getSupportedExtensions({ allowJs: true }, [{ extension: "node", isMixedContent: false }, {
61715
61715
  extension: "json",
@@ -61718,15 +61718,15 @@ ${lanes.join("\n")}
61718
61718
  /* JSON */
61719
61719
  }]));
61720
61720
  for (const e of extensions) {
61721
- const fullPath = path4 + e;
61721
+ const fullPath = path5 + e;
61722
61722
  if (host.fileExists(fullPath)) {
61723
61723
  return fullPath;
61724
61724
  }
61725
61725
  }
61726
61726
  }
61727
- function getPathsRelativeToRootDirs(path4, rootDirs, getCanonicalFileName) {
61727
+ function getPathsRelativeToRootDirs(path5, rootDirs, getCanonicalFileName) {
61728
61728
  return mapDefined(rootDirs, (rootDir) => {
61729
- const relativePath = getRelativePathIfInSameVolume(path4, rootDir, getCanonicalFileName);
61729
+ const relativePath = getRelativePathIfInSameVolume(path5, rootDir, getCanonicalFileName);
61730
61730
  return relativePath !== void 0 && isPathRelativeToParent(relativePath) ? void 0 : relativePath;
61731
61731
  });
61732
61732
  }
@@ -61843,10 +61843,10 @@ ${lanes.join("\n")}
61843
61843
  return void 0;
61844
61844
  }
61845
61845
  }
61846
- function getRelativePathIfInSameVolume(path4, directoryPath, getCanonicalFileName) {
61846
+ function getRelativePathIfInSameVolume(path5, directoryPath, getCanonicalFileName) {
61847
61847
  const relativePath = getRelativePathToDirectoryOrUrl(
61848
61848
  directoryPath,
61849
- path4,
61849
+ path5,
61850
61850
  directoryPath,
61851
61851
  getCanonicalFileName,
61852
61852
  /*isAbsolutePathAnUrl*/
@@ -61854,8 +61854,8 @@ ${lanes.join("\n")}
61854
61854
  );
61855
61855
  return isRootedDiskPath(relativePath) ? void 0 : relativePath;
61856
61856
  }
61857
- function isPathRelativeToParent(path4) {
61858
- return startsWith(path4, "..");
61857
+ function isPathRelativeToParent(path5) {
61858
+ return startsWith(path5, "..");
61859
61859
  }
61860
61860
  function getDefaultResolutionModeForFile(file, host, compilerOptions) {
61861
61861
  return isFullSourceFile(file) ? host.getDefaultResolutionModeForFile(file) : getDefaultResolutionModeForFileWorker(file, compilerOptions);
@@ -76904,10 +76904,10 @@ ${lanes.join("\n")}
76904
76904
  const text4 = identifier.escapedText;
76905
76905
  if (text4) {
76906
76906
  const parentSymbol = name.kind === 167 ? getUnresolvedSymbolForEntityName(name.left) : name.kind === 212 ? getUnresolvedSymbolForEntityName(name.expression) : void 0;
76907
- const path4 = parentSymbol ? `${getSymbolPath(parentSymbol)}.${text4}` : text4;
76908
- let result = unresolvedSymbols.get(path4);
76907
+ const path5 = parentSymbol ? `${getSymbolPath(parentSymbol)}.${text4}` : text4;
76908
+ let result = unresolvedSymbols.get(path5);
76909
76909
  if (!result) {
76910
- unresolvedSymbols.set(path4, result = createSymbol(
76910
+ unresolvedSymbols.set(path5, result = createSymbol(
76911
76911
  524288,
76912
76912
  text4,
76913
76913
  1048576
@@ -81708,24 +81708,24 @@ ${lanes.join("\n")}
81708
81708
  }
81709
81709
  return;
81710
81710
  }
81711
- let path4 = "";
81711
+ let path5 = "";
81712
81712
  const secondaryRootErrors = [];
81713
81713
  while (stack.length) {
81714
81714
  const [msg, ...args] = stack.pop();
81715
81715
  switch (msg.code) {
81716
81716
  case Diagnostics.Types_of_property_0_are_incompatible.code: {
81717
- if (path4.indexOf("new ") === 0) {
81718
- path4 = `(${path4})`;
81717
+ if (path5.indexOf("new ") === 0) {
81718
+ path5 = `(${path5})`;
81719
81719
  }
81720
81720
  const str = "" + args[0];
81721
- if (path4.length === 0) {
81722
- path4 = `${str}`;
81721
+ if (path5.length === 0) {
81722
+ path5 = `${str}`;
81723
81723
  } else if (isIdentifierText(str, getEmitScriptTarget(compilerOptions))) {
81724
- path4 = `${path4}.${str}`;
81724
+ path5 = `${path5}.${str}`;
81725
81725
  } else if (str[0] === "[" && str[str.length - 1] === "]") {
81726
- path4 = `${path4}${str}`;
81726
+ path5 = `${path5}${str}`;
81727
81727
  } else {
81728
- path4 = `${path4}[${str}]`;
81728
+ path5 = `${path5}[${str}]`;
81729
81729
  }
81730
81730
  break;
81731
81731
  }
@@ -81733,7 +81733,7 @@ ${lanes.join("\n")}
81733
81733
  case Diagnostics.Construct_signature_return_types_0_and_1_are_incompatible.code:
81734
81734
  case Diagnostics.Call_signatures_with_no_arguments_have_incompatible_return_types_0_and_1.code:
81735
81735
  case Diagnostics.Construct_signatures_with_no_arguments_have_incompatible_return_types_0_and_1.code: {
81736
- if (path4.length === 0) {
81736
+ if (path5.length === 0) {
81737
81737
  let mappedMsg = msg;
81738
81738
  if (msg.code === Diagnostics.Call_signatures_with_no_arguments_have_incompatible_return_types_0_and_1.code) {
81739
81739
  mappedMsg = Diagnostics.Call_signature_return_types_0_and_1_are_incompatible;
@@ -81744,7 +81744,7 @@ ${lanes.join("\n")}
81744
81744
  } else {
81745
81745
  const prefix = msg.code === Diagnostics.Construct_signature_return_types_0_and_1_are_incompatible.code || msg.code === Diagnostics.Construct_signatures_with_no_arguments_have_incompatible_return_types_0_and_1.code ? "new " : "";
81746
81746
  const params = msg.code === Diagnostics.Call_signatures_with_no_arguments_have_incompatible_return_types_0_and_1.code || msg.code === Diagnostics.Construct_signatures_with_no_arguments_have_incompatible_return_types_0_and_1.code ? "" : "...";
81747
- path4 = `${prefix}${path4}(${params})`;
81747
+ path5 = `${prefix}${path5}(${params})`;
81748
81748
  }
81749
81749
  break;
81750
81750
  }
@@ -81760,10 +81760,10 @@ ${lanes.join("\n")}
81760
81760
  return Debug.fail(`Unhandled Diagnostic: ${msg.code}`);
81761
81761
  }
81762
81762
  }
81763
- if (path4) {
81763
+ if (path5) {
81764
81764
  reportError(
81765
- path4[path4.length - 1] === ")" ? Diagnostics.The_types_returned_by_0_are_incompatible_between_these_types : Diagnostics.The_types_of_0_are_incompatible_between_these_types,
81766
- path4
81765
+ path5[path5.length - 1] === ")" ? Diagnostics.The_types_returned_by_0_are_incompatible_between_these_types : Diagnostics.The_types_of_0_are_incompatible_between_these_types,
81766
+ path5
81767
81767
  );
81768
81768
  } else {
81769
81769
  secondaryRootErrors.shift();
@@ -136831,9 +136831,9 @@ ${lanes.join("\n")}
136831
136831
  function createAddOutput() {
136832
136832
  let outputs;
136833
136833
  return { addOutput, getOutputs };
136834
- function addOutput(path4) {
136835
- if (path4) {
136836
- (outputs || (outputs = [])).push(path4);
136834
+ function addOutput(path5) {
136835
+ if (path5) {
136836
+ (outputs || (outputs = [])).push(path5);
136837
136837
  }
136838
136838
  }
136839
136839
  function getOutputs() {
@@ -142059,7 +142059,7 @@ ${lanes.join("\n")}
142059
142059
  return {
142060
142060
  useCaseSensitiveFileNames: useCaseSensitiveFileNames2,
142061
142061
  fileExists,
142062
- readFile: (path4, encoding) => host.readFile(path4, encoding),
142062
+ readFile: (path5, encoding) => host.readFile(path5, encoding),
142063
142063
  directoryExists: host.directoryExists && directoryExists,
142064
142064
  getDirectories,
142065
142065
  readDirectory,
@@ -142076,8 +142076,8 @@ ${lanes.join("\n")}
142076
142076
  function getCachedFileSystemEntries(rootDirPath) {
142077
142077
  return cachedReadDirectoryResult.get(ensureTrailingDirectorySeparator(rootDirPath));
142078
142078
  }
142079
- function getCachedFileSystemEntriesForBaseDir(path4) {
142080
- const entries = getCachedFileSystemEntries(getDirectoryPath(path4));
142079
+ function getCachedFileSystemEntriesForBaseDir(path5) {
142080
+ const entries = getCachedFileSystemEntries(getDirectoryPath(path5));
142081
142081
  if (!entries) {
142082
142082
  return entries;
142083
142083
  }
@@ -142132,8 +142132,8 @@ ${lanes.join("\n")}
142132
142132
  return index2 >= 0;
142133
142133
  }
142134
142134
  function writeFile2(fileName, data, writeByteOrderMark) {
142135
- const path4 = toPath3(fileName);
142136
- const result = getCachedFileSystemEntriesForBaseDir(path4);
142135
+ const path5 = toPath3(fileName);
142136
+ const result = getCachedFileSystemEntriesForBaseDir(path5);
142137
142137
  if (result) {
142138
142138
  updateFilesOfFileSystemEntry(
142139
142139
  result,
@@ -142145,17 +142145,17 @@ ${lanes.join("\n")}
142145
142145
  return host.writeFile(fileName, data, writeByteOrderMark);
142146
142146
  }
142147
142147
  function fileExists(fileName) {
142148
- const path4 = toPath3(fileName);
142149
- const result = getCachedFileSystemEntriesForBaseDir(path4);
142148
+ const path5 = toPath3(fileName);
142149
+ const result = getCachedFileSystemEntriesForBaseDir(path5);
142150
142150
  return result && hasEntry(result.sortedAndCanonicalizedFiles, getCanonicalFileName(getBaseNameOfFileName(fileName))) || host.fileExists(fileName);
142151
142151
  }
142152
142152
  function directoryExists(dirPath) {
142153
- const path4 = toPath3(dirPath);
142154
- return cachedReadDirectoryResult.has(ensureTrailingDirectorySeparator(path4)) || host.directoryExists(dirPath);
142153
+ const path5 = toPath3(dirPath);
142154
+ return cachedReadDirectoryResult.has(ensureTrailingDirectorySeparator(path5)) || host.directoryExists(dirPath);
142155
142155
  }
142156
142156
  function createDirectory(dirPath) {
142157
- const path4 = toPath3(dirPath);
142158
- const result = getCachedFileSystemEntriesForBaseDir(path4);
142157
+ const path5 = toPath3(dirPath);
142158
+ const result = getCachedFileSystemEntriesForBaseDir(path5);
142159
142159
  if (result) {
142160
142160
  const baseName = getBaseNameOfFileName(dirPath);
142161
142161
  const canonicalizedBaseName = getCanonicalFileName(baseName);
@@ -142183,15 +142183,15 @@ ${lanes.join("\n")}
142183
142183
  }
142184
142184
  return host.readDirectory(rootDir, extensions, excludes, includes, depth);
142185
142185
  function getFileSystemEntries(dir) {
142186
- const path4 = toPath3(dir);
142187
- if (path4 === rootDirPath) {
142188
- return rootResult || getFileSystemEntriesFromHost(dir, path4);
142186
+ const path5 = toPath3(dir);
142187
+ if (path5 === rootDirPath) {
142188
+ return rootResult || getFileSystemEntriesFromHost(dir, path5);
142189
142189
  }
142190
- const result = tryReadDirectory2(dir, path4);
142191
- return result !== void 0 ? result || getFileSystemEntriesFromHost(dir, path4) : emptyFileSystemEntries;
142190
+ const result = tryReadDirectory2(dir, path5);
142191
+ return result !== void 0 ? result || getFileSystemEntriesFromHost(dir, path5) : emptyFileSystemEntries;
142192
142192
  }
142193
- function getFileSystemEntriesFromHost(dir, path4) {
142194
- if (rootSymLinkResult && path4 === rootDirPath) return rootSymLinkResult;
142193
+ function getFileSystemEntriesFromHost(dir, path5) {
142194
+ if (rootSymLinkResult && path5 === rootDirPath) return rootSymLinkResult;
142195
142195
  const result = {
142196
142196
  files: map(host.readDirectory(
142197
142197
  dir,
@@ -142204,7 +142204,7 @@ ${lanes.join("\n")}
142204
142204
  ), getBaseNameOfFileName) || emptyArray,
142205
142205
  directories: host.getDirectories(dir) || emptyArray
142206
142206
  };
142207
- if (path4 === rootDirPath) rootSymLinkResult = result;
142207
+ if (path5 === rootDirPath) rootSymLinkResult = result;
142208
142208
  return result;
142209
142209
  }
142210
142210
  }
@@ -142663,15 +142663,15 @@ ${lanes.join("\n")}
142663
142663
  return getDirectoryPath(normalizePath(system.getExecutingFilePath()));
142664
142664
  }
142665
142665
  const newLine = getNewLineCharacter(options);
142666
- const realpath = system.realpath && ((path4) => system.realpath(path4));
142666
+ const realpath = system.realpath && ((path5) => system.realpath(path5));
142667
142667
  const compilerHost = {
142668
142668
  getSourceFile: createGetSourceFile((fileName) => compilerHost.readFile(fileName), setParentNodes),
142669
142669
  getDefaultLibLocation,
142670
142670
  getDefaultLibFileName: (options2) => combinePaths(getDefaultLibLocation(), getDefaultLibFileName(options2)),
142671
142671
  writeFile: createWriteFileMeasuringIO(
142672
- (path4, data, writeByteOrderMark) => system.writeFile(path4, data, writeByteOrderMark),
142673
- (path4) => (compilerHost.createDirectory || system.createDirectory)(path4),
142674
- (path4) => directoryExists(path4)
142672
+ (path5, data, writeByteOrderMark) => system.writeFile(path5, data, writeByteOrderMark),
142673
+ (path5) => (compilerHost.createDirectory || system.createDirectory)(path5),
142674
+ (path5) => directoryExists(path5)
142675
142675
  ),
142676
142676
  getCurrentDirectory: memoize(() => system.getCurrentDirectory()),
142677
142677
  useCaseSensitiveFileNames: () => system.useCaseSensitiveFileNames,
@@ -142682,9 +142682,9 @@ ${lanes.join("\n")}
142682
142682
  trace: (s) => system.write(s + newLine),
142683
142683
  directoryExists: (directoryName) => system.directoryExists(directoryName),
142684
142684
  getEnvironmentVariable: (name) => system.getEnvironmentVariable ? system.getEnvironmentVariable(name) : "",
142685
- getDirectories: (path4) => system.getDirectories(path4),
142685
+ getDirectories: (path5) => system.getDirectories(path5),
142686
142686
  realpath,
142687
- readDirectory: (path4, extensions, include, exclude, depth) => system.readDirectory(path4, extensions, include, exclude, depth),
142687
+ readDirectory: (path5, extensions, include, exclude, depth) => system.readDirectory(path5, extensions, include, exclude, depth),
142688
142688
  createDirectory: (d) => system.createDirectory(d),
142689
142689
  createHash: maybeBind(system, system.createHash)
142690
142690
  };
@@ -143123,13 +143123,13 @@ ${lanes.join("\n")}
143123
143123
  }
143124
143124
  function getLibraryNameFromLibFileName(libFileName) {
143125
143125
  const components = libFileName.split(".");
143126
- let path4 = components[1];
143126
+ let path5 = components[1];
143127
143127
  let i = 2;
143128
143128
  while (components[i] && components[i] !== "d") {
143129
- path4 += (i === 2 ? "/" : "-") + components[i];
143129
+ path5 += (i === 2 ? "/" : "-") + components[i];
143130
143130
  i++;
143131
143131
  }
143132
- return "@typescript/lib-" + path4;
143132
+ return "@typescript/lib-" + path5;
143133
143133
  }
143134
143134
  function isReferencedFile(reason) {
143135
143135
  switch (reason == null ? void 0 : reason.kind) {
@@ -144205,18 +144205,18 @@ ${lanes.join("\n")}
144205
144205
  filesByName.set(newSourceFile.path, newSourceFile);
144206
144206
  }
144207
144207
  const oldFilesByNameMap = oldProgram.getFilesByNameMap();
144208
- oldFilesByNameMap.forEach((oldFile, path4) => {
144208
+ oldFilesByNameMap.forEach((oldFile, path5) => {
144209
144209
  if (!oldFile) {
144210
- filesByName.set(path4, oldFile);
144210
+ filesByName.set(path5, oldFile);
144211
144211
  return;
144212
144212
  }
144213
- if (oldFile.path === path4) {
144213
+ if (oldFile.path === path5) {
144214
144214
  if (oldProgram.isSourceFileFromExternalLibrary(oldFile)) {
144215
144215
  sourceFilesFoundSearchingNodeModules.set(oldFile.path, true);
144216
144216
  }
144217
144217
  return;
144218
144218
  }
144219
- filesByName.set(path4, filesByName.get(oldFile.path));
144219
+ filesByName.set(path5, filesByName.get(oldFile.path));
144220
144220
  });
144221
144221
  const isConfigIdentical = oldOptions.configFile && oldOptions.configFile === options.configFile || !oldOptions.configFile && !options.configFile && !optionsHaveChanges(oldOptions, options, optionDeclarations);
144222
144222
  programDiagnostics.reuseStateFromOldProgram(oldProgram.getProgramDiagnosticsContainer(), isConfigIdentical);
@@ -144254,9 +144254,9 @@ ${lanes.join("\n")}
144254
144254
  getModeForResolutionAtIndex: getModeForResolutionAtIndex2,
144255
144255
  readFile: (f) => host.readFile(f),
144256
144256
  fileExists: (f) => {
144257
- const path4 = toPath3(f);
144258
- if (getSourceFileByPath(path4)) return true;
144259
- if (missingFileNames.has(path4)) return false;
144257
+ const path5 = toPath3(f);
144258
+ if (getSourceFileByPath(path5)) return true;
144259
+ if (missingFileNames.has(path5)) return false;
144260
144260
  return host.fileExists(f);
144261
144261
  },
144262
144262
  realpath: maybeBind(host, host.realpath),
@@ -144396,8 +144396,8 @@ ${lanes.join("\n")}
144396
144396
  function getSourceFile(fileName) {
144397
144397
  return getSourceFileByPath(toPath3(fileName));
144398
144398
  }
144399
- function getSourceFileByPath(path4) {
144400
- return filesByName.get(path4) || void 0;
144399
+ function getSourceFileByPath(path5) {
144400
+ return filesByName.get(path5) || void 0;
144401
144401
  }
144402
144402
  function getDiagnosticsHelper(sourceFile, getDiagnostics2, cancellationToken) {
144403
144403
  if (sourceFile) {
@@ -145040,16 +145040,16 @@ ${lanes.join("\n")}
145040
145040
  addFilePreprocessingFileExplainingDiagnostic(existingFile, reason, Diagnostics.File_name_0_differs_from_already_included_file_name_1_only_in_casing, [fileName, existingFile.fileName]);
145041
145041
  }
145042
145042
  }
145043
- function createRedirectedSourceFile(redirectTarget, unredirected, fileName, path4, resolvedPath, originalFileName, sourceFileOptions) {
145043
+ function createRedirectedSourceFile(redirectTarget, unredirected, fileName, path5, resolvedPath, originalFileName, sourceFileOptions) {
145044
145044
  var _a2;
145045
145045
  const redirect = parseNodeFactory.createRedirectedSourceFile({ redirectTarget, unredirected });
145046
145046
  redirect.fileName = fileName;
145047
- redirect.path = path4;
145047
+ redirect.path = path5;
145048
145048
  redirect.resolvedPath = resolvedPath;
145049
145049
  redirect.originalFileName = originalFileName;
145050
145050
  redirect.packageJsonLocations = ((_a2 = sourceFileOptions.packageJsonLocations) == null ? void 0 : _a2.length) ? sourceFileOptions.packageJsonLocations : void 0;
145051
145051
  redirect.packageJsonScope = sourceFileOptions.packageJsonScope;
145052
- sourceFilesFoundSearchingNodeModules.set(path4, currentNodeModulesDepth > 0);
145052
+ sourceFilesFoundSearchingNodeModules.set(path5, currentNodeModulesDepth > 0);
145053
145053
  return redirect;
145054
145054
  }
145055
145055
  function findSourceFile(fileName, isDefaultLib, ignoreNoDefaultLib, reason, packageId) {
@@ -145071,18 +145071,18 @@ ${lanes.join("\n")}
145071
145071
  }
145072
145072
  function findSourceFileWorker(fileName, isDefaultLib, ignoreNoDefaultLib, reason, packageId) {
145073
145073
  var _a2, _b2;
145074
- const path4 = toPath3(fileName);
145074
+ const path5 = toPath3(fileName);
145075
145075
  if (useSourceOfProjectReferenceRedirect) {
145076
- let source = getRedirectFromOutput(path4);
145076
+ let source = getRedirectFromOutput(path5);
145077
145077
  if (!source && host.realpath && options.preserveSymlinks && isDeclarationFileName(fileName) && fileName.includes(nodeModulesPathPart)) {
145078
145078
  const realPath2 = toPath3(host.realpath(fileName));
145079
- if (realPath2 !== path4) source = getRedirectFromOutput(realPath2);
145079
+ if (realPath2 !== path5) source = getRedirectFromOutput(realPath2);
145080
145080
  }
145081
145081
  if (source == null ? void 0 : source.source) {
145082
145082
  const file2 = findSourceFile(source.source, isDefaultLib, ignoreNoDefaultLib, reason, packageId);
145083
145083
  if (file2) addFileToFilesByName(
145084
145084
  file2,
145085
- path4,
145085
+ path5,
145086
145086
  fileName,
145087
145087
  /*redirectedPath*/
145088
145088
  void 0
@@ -145091,8 +145091,8 @@ ${lanes.join("\n")}
145091
145091
  }
145092
145092
  }
145093
145093
  const originalFileName = fileName;
145094
- if (filesByName.has(path4)) {
145095
- const file2 = filesByName.get(path4);
145094
+ if (filesByName.has(path5)) {
145095
+ const file2 = filesByName.get(path5);
145096
145096
  const addedReason = addFileIncludeReason(
145097
145097
  file2 || void 0,
145098
145098
  reason,
@@ -145158,28 +145158,28 @@ ${lanes.join("\n")}
145158
145158
  const packageIdKey = packageIdToString(packageId);
145159
145159
  const fileFromPackageId = packageIdToSourceFile.get(packageIdKey);
145160
145160
  if (fileFromPackageId) {
145161
- const dupFile = createRedirectedSourceFile(fileFromPackageId, file, fileName, path4, toPath3(fileName), originalFileName, sourceFileOptions);
145161
+ const dupFile = createRedirectedSourceFile(fileFromPackageId, file, fileName, path5, toPath3(fileName), originalFileName, sourceFileOptions);
145162
145162
  redirectTargetsMap.add(fileFromPackageId.path, fileName);
145163
- addFileToFilesByName(dupFile, path4, fileName, redirectedPath);
145163
+ addFileToFilesByName(dupFile, path5, fileName, redirectedPath);
145164
145164
  addFileIncludeReason(
145165
145165
  dupFile,
145166
145166
  reason,
145167
145167
  /*checkExisting*/
145168
145168
  false
145169
145169
  );
145170
- sourceFileToPackageName.set(path4, packageIdToPackageName(packageId));
145170
+ sourceFileToPackageName.set(path5, packageIdToPackageName(packageId));
145171
145171
  processingOtherFiles.push(dupFile);
145172
145172
  return dupFile;
145173
145173
  } else if (file) {
145174
145174
  packageIdToSourceFile.set(packageIdKey, file);
145175
- sourceFileToPackageName.set(path4, packageIdToPackageName(packageId));
145175
+ sourceFileToPackageName.set(path5, packageIdToPackageName(packageId));
145176
145176
  }
145177
145177
  }
145178
- addFileToFilesByName(file, path4, fileName, redirectedPath);
145178
+ addFileToFilesByName(file, path5, fileName, redirectedPath);
145179
145179
  if (file) {
145180
- sourceFilesFoundSearchingNodeModules.set(path4, currentNodeModulesDepth > 0);
145180
+ sourceFilesFoundSearchingNodeModules.set(path5, currentNodeModulesDepth > 0);
145181
145181
  file.fileName = fileName;
145182
- file.path = path4;
145182
+ file.path = path5;
145183
145183
  file.resolvedPath = toPath3(fileName);
145184
145184
  file.originalFileName = originalFileName;
145185
145185
  file.packageJsonLocations = ((_b2 = sourceFileOptions.packageJsonLocations) == null ? void 0 : _b2.length) ? sourceFileOptions.packageJsonLocations : void 0;
@@ -145191,7 +145191,7 @@ ${lanes.join("\n")}
145191
145191
  false
145192
145192
  );
145193
145193
  if (host.useCaseSensitiveFileNames()) {
145194
- const pathLowerCase = toFileNameLowerCase(path4);
145194
+ const pathLowerCase = toFileNameLowerCase(path5);
145195
145195
  const existingFile = filesByNameIgnoreCase.get(pathLowerCase);
145196
145196
  if (existingFile) {
145197
145197
  reportFileNamesDifferOnlyInCasingError(fileName, existingFile, reason);
@@ -145224,18 +145224,18 @@ ${lanes.join("\n")}
145224
145224
  }
145225
145225
  return false;
145226
145226
  }
145227
- function addFileToFilesByName(file, path4, fileName, redirectedPath) {
145227
+ function addFileToFilesByName(file, path5, fileName, redirectedPath) {
145228
145228
  if (redirectedPath) {
145229
145229
  updateFilesByNameMap(fileName, redirectedPath, file);
145230
- updateFilesByNameMap(fileName, path4, file || false);
145230
+ updateFilesByNameMap(fileName, path5, file || false);
145231
145231
  } else {
145232
- updateFilesByNameMap(fileName, path4, file);
145232
+ updateFilesByNameMap(fileName, path5, file);
145233
145233
  }
145234
145234
  }
145235
- function updateFilesByNameMap(fileName, path4, file) {
145236
- filesByName.set(path4, file);
145237
- if (file !== void 0) missingFileNames.delete(path4);
145238
- else missingFileNames.set(path4, fileName);
145235
+ function updateFilesByNameMap(fileName, path5, file) {
145236
+ filesByName.set(path5, file);
145237
+ if (file !== void 0) missingFileNames.delete(path5);
145238
+ else missingFileNames.set(path5, fileName);
145239
145239
  }
145240
145240
  function getRedirectFromSourceFile(fileName) {
145241
145241
  return mapSourceFileToResolvedRef == null ? void 0 : mapSourceFileToResolvedRef.get(toPath3(fileName));
@@ -145243,8 +145243,8 @@ ${lanes.join("\n")}
145243
145243
  function forEachResolvedProjectReference2(cb) {
145244
145244
  return forEachResolvedProjectReference(resolvedProjectReferences, cb);
145245
145245
  }
145246
- function getRedirectFromOutput(path4) {
145247
- return mapOutputFileToResolvedRef == null ? void 0 : mapOutputFileToResolvedRef.get(path4);
145246
+ function getRedirectFromOutput(path5) {
145247
+ return mapOutputFileToResolvedRef == null ? void 0 : mapOutputFileToResolvedRef.get(path5);
145248
145248
  }
145249
145249
  function isSourceOfProjectReferenceRedirect(fileName) {
145250
145250
  return useSourceOfProjectReferenceRedirect && !!getRedirectFromSourceFile(fileName);
@@ -145543,7 +145543,7 @@ ${lanes.join("\n")}
145543
145543
  }
145544
145544
  const getCommonSourceDirectory3 = memoize(() => getCommonSourceDirectoryOfConfig(resolvedRef.commandLine, !host.useCaseSensitiveFileNames()));
145545
145545
  commandLine.fileNames.forEach((fileName) => {
145546
- const path4 = toPath3(fileName);
145546
+ const path5 = toPath3(fileName);
145547
145547
  let outputDts;
145548
145548
  if (!isDeclarationFileName(fileName) && !fileExtensionIs(
145549
145549
  fileName,
@@ -145557,7 +145557,7 @@ ${lanes.join("\n")}
145557
145557
  outputDts = outDts;
145558
145558
  }
145559
145559
  }
145560
- mapSourceFileToResolvedRef.set(path4, { resolvedRef, outputDts });
145560
+ mapSourceFileToResolvedRef.set(path5, { resolvedRef, outputDts });
145561
145561
  });
145562
145562
  }
145563
145563
  if (commandLine.projectReferences) {
@@ -146245,9 +146245,9 @@ ${lanes.join("\n")}
146245
146245
  host.compilerHost.fileExists = fileExists;
146246
146246
  let directoryExists;
146247
146247
  if (originalDirectoryExists) {
146248
- directoryExists = host.compilerHost.directoryExists = (path4) => {
146249
- if (originalDirectoryExists.call(host.compilerHost, path4)) {
146250
- handleDirectoryCouldBeSymlink(path4);
146248
+ directoryExists = host.compilerHost.directoryExists = (path5) => {
146249
+ if (originalDirectoryExists.call(host.compilerHost, path5)) {
146250
+ handleDirectoryCouldBeSymlink(path5);
146251
146251
  return true;
146252
146252
  }
146253
146253
  if (!host.getResolvedProjectReferences()) return false;
@@ -146266,14 +146266,14 @@ ${lanes.join("\n")}
146266
146266
  });
146267
146267
  }
146268
146268
  return fileOrDirectoryExistsUsingSource(
146269
- path4,
146269
+ path5,
146270
146270
  /*isFile*/
146271
146271
  false
146272
146272
  );
146273
146273
  };
146274
146274
  }
146275
146275
  if (originalGetDirectories) {
146276
- host.compilerHost.getDirectories = (path4) => !host.getResolvedProjectReferences() || originalDirectoryExists && originalDirectoryExists.call(host.compilerHost, path4) ? originalGetDirectories.call(host.compilerHost, path4) : [];
146276
+ host.compilerHost.getDirectories = (path5) => !host.getResolvedProjectReferences() || originalDirectoryExists && originalDirectoryExists.call(host.compilerHost, path5) ? originalGetDirectories.call(host.compilerHost, path5) : [];
146277
146277
  }
146278
146278
  if (originalRealpath) {
146279
146279
  host.compilerHost.realpath = (s) => {
@@ -146940,12 +146940,12 @@ ${lanes.join("\n")}
146940
146940
  state.allFileNames = void 0;
146941
146941
  }
146942
146942
  BuilderState2.releaseCache = releaseCache2;
146943
- function getFilesAffectedBy(state, programOfThisState, path4, cancellationToken, host) {
146943
+ function getFilesAffectedBy(state, programOfThisState, path5, cancellationToken, host) {
146944
146944
  var _a;
146945
146945
  const result = getFilesAffectedByWithOldState(
146946
146946
  state,
146947
146947
  programOfThisState,
146948
- path4,
146948
+ path5,
146949
146949
  cancellationToken,
146950
146950
  host
146951
146951
  );
@@ -146953,8 +146953,8 @@ ${lanes.join("\n")}
146953
146953
  return result;
146954
146954
  }
146955
146955
  BuilderState2.getFilesAffectedBy = getFilesAffectedBy;
146956
- function getFilesAffectedByWithOldState(state, programOfThisState, path4, cancellationToken, host) {
146957
- const sourceFile = programOfThisState.getSourceFileByPath(path4);
146956
+ function getFilesAffectedByWithOldState(state, programOfThisState, path5, cancellationToken, host) {
146957
+ const sourceFile = programOfThisState.getSourceFileByPath(path5);
146958
146958
  if (!sourceFile) {
146959
146959
  return emptyArray;
146960
146960
  }
@@ -146964,9 +146964,9 @@ ${lanes.join("\n")}
146964
146964
  return (state.referencedMap ? getFilesAffectedByUpdatedShapeWhenModuleEmit : getFilesAffectedByUpdatedShapeWhenNonModuleEmit)(state, programOfThisState, sourceFile, cancellationToken, host);
146965
146965
  }
146966
146966
  BuilderState2.getFilesAffectedByWithOldState = getFilesAffectedByWithOldState;
146967
- function updateSignatureOfFile(state, signature, path4) {
146968
- state.fileInfos.get(path4).signature = signature;
146969
- (state.hasCalledUpdateShapeSignature || (state.hasCalledUpdateShapeSignature = /* @__PURE__ */ new Set())).add(path4);
146967
+ function updateSignatureOfFile(state, signature, path5) {
146968
+ state.fileInfos.get(path5).signature = signature;
146969
+ (state.hasCalledUpdateShapeSignature || (state.hasCalledUpdateShapeSignature = /* @__PURE__ */ new Set())).add(path5);
146970
146970
  }
146971
146971
  BuilderState2.updateSignatureOfFile = updateSignatureOfFile;
146972
146972
  function computeDtsSignature(programOfThisState, sourceFile, cancellationToken, host, onNewSignature) {
@@ -147035,10 +147035,10 @@ ${lanes.join("\n")}
147035
147035
  const seenMap = /* @__PURE__ */ new Set();
147036
147036
  const queue = [sourceFile.resolvedPath];
147037
147037
  while (queue.length) {
147038
- const path4 = queue.pop();
147039
- if (!seenMap.has(path4)) {
147040
- seenMap.add(path4);
147041
- const references = state.referencedMap.getValues(path4);
147038
+ const path5 = queue.pop();
147039
+ if (!seenMap.has(path5)) {
147040
+ seenMap.add(path5);
147041
+ const references = state.referencedMap.getValues(path5);
147042
147042
  if (references) {
147043
147043
  for (const key of references.keys()) {
147044
147044
  queue.push(key);
@@ -147046,9 +147046,9 @@ ${lanes.join("\n")}
147046
147046
  }
147047
147047
  }
147048
147048
  }
147049
- return arrayFrom(mapDefinedIterator(seenMap.keys(), (path4) => {
147049
+ return arrayFrom(mapDefinedIterator(seenMap.keys(), (path5) => {
147050
147050
  var _a;
147051
- return ((_a = programOfThisState.getSourceFileByPath(path4)) == null ? void 0 : _a.fileName) ?? path4;
147051
+ return ((_a = programOfThisState.getSourceFileByPath(path5)) == null ? void 0 : _a.fileName) ?? path5;
147052
147052
  }));
147053
147053
  }
147054
147054
  BuilderState2.getAllDependencies = getAllDependencies;
@@ -147227,7 +147227,7 @@ ${lanes.join("\n")}
147227
147227
  oldInfo.version !== info.version || // Implied formats dont match
147228
147228
  oldInfo.impliedFormat !== info.impliedFormat || // Referenced files changed
147229
147229
  !hasSameKeys(newReferences = referencedMap && referencedMap.getValues(sourceFilePath), oldReferencedMap && oldReferencedMap.getValues(sourceFilePath)) || // Referenced file was deleted in the new program
147230
- newReferences && forEachKey(newReferences, (path4) => !state.fileInfos.has(path4) && oldState.fileInfos.has(path4))) {
147230
+ newReferences && forEachKey(newReferences, (path5) => !state.fileInfos.has(path5) && oldState.fileInfos.has(path5))) {
147231
147231
  addFileToChangeSet(sourceFilePath);
147232
147232
  } else {
147233
147233
  const sourceFile = newProgram.getSourceFileByPath(sourceFilePath);
@@ -147293,8 +147293,8 @@ ${lanes.join("\n")}
147293
147293
  }
147294
147294
  if (useOldState && state.semanticDiagnosticsPerFile.size !== state.fileInfos.size && oldState.checkPending !== state.checkPending) state.buildInfoEmitPending = true;
147295
147295
  return state;
147296
- function addFileToChangeSet(path4) {
147297
- state.changedFilesSet.add(path4);
147296
+ function addFileToChangeSet(path5) {
147297
+ state.changedFilesSet.add(path5);
147298
147298
  if (outFilePath) {
147299
147299
  canCopySemanticDiagnostics = false;
147300
147300
  canCopyEmitDiagnostics = false;
@@ -147358,9 +147358,9 @@ ${lanes.join("\n")}
147358
147358
  result.relatedInformation = relatedInformation ? relatedInformation.length ? relatedInformation.map((r) => convertToDiagnosticRelatedInformation(r, diagnosticFilePath, newProgram, toPathInBuildInfoDirectory)) : [] : void 0;
147359
147359
  return result;
147360
147360
  });
147361
- function toPathInBuildInfoDirectory(path4) {
147361
+ function toPathInBuildInfoDirectory(path5) {
147362
147362
  buildInfoDirectory ?? (buildInfoDirectory = getDirectoryPath(getNormalizedAbsolutePath(getTsBuildInfoEmitOutputFilePath(newProgram.getCompilerOptions()), newProgram.getCurrentDirectory())));
147363
- return toPath(path4, buildInfoDirectory, newProgram.getCanonicalFileName);
147363
+ return toPath(path5, buildInfoDirectory, newProgram.getCanonicalFileName);
147364
147364
  }
147365
147365
  }
147366
147366
  function convertToDiagnosticRelatedInformation(diagnostic, diagnosticFilePath, newProgram, toPath3) {
@@ -147435,10 +147435,10 @@ ${lanes.join("\n")}
147435
147435
  state.affectedFilesPendingEmit = void 0;
147436
147436
  state.programEmitPending = void 0;
147437
147437
  }
147438
- (_b = state.affectedFilesPendingEmit) == null ? void 0 : _b.forEach((emitKind, path4) => {
147438
+ (_b = state.affectedFilesPendingEmit) == null ? void 0 : _b.forEach((emitKind, path5) => {
147439
147439
  const pending = !isForDtsErrors ? emitKind & 7 : emitKind & (7 | 48);
147440
- if (!pending) state.affectedFilesPendingEmit.delete(path4);
147441
- else state.affectedFilesPendingEmit.set(path4, pending);
147440
+ if (!pending) state.affectedFilesPendingEmit.delete(path5);
147441
+ else state.affectedFilesPendingEmit.set(path5, pending);
147442
147442
  });
147443
147443
  if (state.programEmitPending) {
147444
147444
  const pending = !isForDtsErrors ? state.programEmitPending & 7 : state.programEmitPending & (7 | 48);
@@ -147458,11 +147458,11 @@ ${lanes.join("\n")}
147458
147458
  function getNextAffectedFilePendingEmit(state, emitOnlyDtsFiles, isForDtsErrors) {
147459
147459
  var _a;
147460
147460
  if (!((_a = state.affectedFilesPendingEmit) == null ? void 0 : _a.size)) return void 0;
147461
- return forEachEntry(state.affectedFilesPendingEmit, (emitKind, path4) => {
147461
+ return forEachEntry(state.affectedFilesPendingEmit, (emitKind, path5) => {
147462
147462
  var _a2;
147463
- const affectedFile = state.program.getSourceFileByPath(path4);
147463
+ const affectedFile = state.program.getSourceFileByPath(path5);
147464
147464
  if (!affectedFile || !sourceFileMayBeEmitted(affectedFile, state.program)) {
147465
- state.affectedFilesPendingEmit.delete(path4);
147465
+ state.affectedFilesPendingEmit.delete(path5);
147466
147466
  return void 0;
147467
147467
  }
147468
147468
  const seenKind = (_a2 = state.seenEmittedFiles) == null ? void 0 : _a2.get(affectedFile.resolvedPath);
@@ -147478,11 +147478,11 @@ ${lanes.join("\n")}
147478
147478
  function getNextPendingEmitDiagnosticsFile(state, isForDtsErrors) {
147479
147479
  var _a;
147480
147480
  if (!((_a = state.emitDiagnosticsPerFile) == null ? void 0 : _a.size)) return void 0;
147481
- return forEachEntry(state.emitDiagnosticsPerFile, (diagnostics, path4) => {
147481
+ return forEachEntry(state.emitDiagnosticsPerFile, (diagnostics, path5) => {
147482
147482
  var _a2;
147483
- const affectedFile = state.program.getSourceFileByPath(path4);
147483
+ const affectedFile = state.program.getSourceFileByPath(path5);
147484
147484
  if (!affectedFile || !sourceFileMayBeEmitted(affectedFile, state.program)) {
147485
- state.emitDiagnosticsPerFile.delete(path4);
147485
+ state.emitDiagnosticsPerFile.delete(path5);
147486
147486
  return void 0;
147487
147487
  }
147488
147488
  const seenKind = ((_a2 = state.seenEmittedFiles) == null ? void 0 : _a2.get(affectedFile.resolvedPath)) || 0;
@@ -147517,10 +147517,10 @@ ${lanes.join("\n")}
147517
147517
  host
147518
147518
  );
147519
147519
  }
147520
- function handleDtsMayChangeOf(state, path4, invalidateJsFiles, cancellationToken, host) {
147521
- removeSemanticDiagnosticsOf(state, path4);
147522
- if (!state.changedFilesSet.has(path4)) {
147523
- const sourceFile = state.program.getSourceFileByPath(path4);
147520
+ function handleDtsMayChangeOf(state, path5, invalidateJsFiles, cancellationToken, host) {
147521
+ removeSemanticDiagnosticsOf(state, path5);
147522
+ if (!state.changedFilesSet.has(path5)) {
147523
+ const sourceFile = state.program.getSourceFileByPath(path5);
147524
147524
  if (sourceFile) {
147525
147525
  BuilderState.updateShapeSignature(
147526
147526
  state,
@@ -147534,13 +147534,13 @@ ${lanes.join("\n")}
147534
147534
  if (invalidateJsFiles) {
147535
147535
  addToAffectedFilesPendingEmit(
147536
147536
  state,
147537
- path4,
147537
+ path5,
147538
147538
  getBuilderFileEmit(state.compilerOptions)
147539
147539
  );
147540
147540
  } else if (getEmitDeclarations(state.compilerOptions)) {
147541
147541
  addToAffectedFilesPendingEmit(
147542
147542
  state,
147543
- path4,
147543
+ path5,
147544
147544
  state.compilerOptions.declarationMap ? 56 : 24
147545
147545
  /* Dts */
147546
147546
  );
@@ -147548,17 +147548,17 @@ ${lanes.join("\n")}
147548
147548
  }
147549
147549
  }
147550
147550
  }
147551
- function removeSemanticDiagnosticsOf(state, path4) {
147551
+ function removeSemanticDiagnosticsOf(state, path5) {
147552
147552
  if (!state.semanticDiagnosticsFromOldState) {
147553
147553
  return true;
147554
147554
  }
147555
- state.semanticDiagnosticsFromOldState.delete(path4);
147556
- state.semanticDiagnosticsPerFile.delete(path4);
147555
+ state.semanticDiagnosticsFromOldState.delete(path5);
147556
+ state.semanticDiagnosticsPerFile.delete(path5);
147557
147557
  return !state.semanticDiagnosticsFromOldState.size;
147558
147558
  }
147559
- function isChangedSignature(state, path4) {
147560
- const oldSignature = Debug.checkDefined(state.oldSignatures).get(path4) || void 0;
147561
- const newSignature = Debug.checkDefined(state.fileInfos.get(path4)).signature;
147559
+ function isChangedSignature(state, path5) {
147560
+ const oldSignature = Debug.checkDefined(state.oldSignatures).get(path5) || void 0;
147561
+ const newSignature = Debug.checkDefined(state.fileInfos.get(path5)).signature;
147562
147562
  return newSignature !== oldSignature;
147563
147563
  }
147564
147564
  function handleDtsMayChangeOfGlobalScope(state, filePath, invalidateJsFiles, cancellationToken, host) {
@@ -147665,13 +147665,13 @@ ${lanes.join("\n")}
147665
147665
  }
147666
147666
  function getBinderAndCheckerDiagnosticsOfFile(state, sourceFile, cancellationToken, semanticDiagnosticsPerFile) {
147667
147667
  semanticDiagnosticsPerFile ?? (semanticDiagnosticsPerFile = state.semanticDiagnosticsPerFile);
147668
- const path4 = sourceFile.resolvedPath;
147669
- const cachedDiagnostics = semanticDiagnosticsPerFile.get(path4);
147668
+ const path5 = sourceFile.resolvedPath;
147669
+ const cachedDiagnostics = semanticDiagnosticsPerFile.get(path5);
147670
147670
  if (cachedDiagnostics) {
147671
147671
  return filterSemanticDiagnostics(cachedDiagnostics, state.compilerOptions);
147672
147672
  }
147673
147673
  const diagnostics = state.program.getBindAndCheckDiagnostics(sourceFile, cancellationToken);
147674
- semanticDiagnosticsPerFile.set(path4, diagnostics);
147674
+ semanticDiagnosticsPerFile.set(path5, diagnostics);
147675
147675
  state.buildInfoEmitPending = true;
147676
147676
  return filterSemanticDiagnostics(diagnostics, state.compilerOptions);
147677
147677
  }
@@ -147819,11 +147819,11 @@ ${lanes.join("\n")}
147819
147819
  if ((_b = state.affectedFilesPendingEmit) == null ? void 0 : _b.size) {
147820
147820
  const fullEmitForOptions = getBuilderFileEmit(state.compilerOptions);
147821
147821
  const seenFiles = /* @__PURE__ */ new Set();
147822
- for (const path4 of arrayFrom(state.affectedFilesPendingEmit.keys()).sort(compareStringsCaseSensitive)) {
147823
- if (tryAddToSet(seenFiles, path4)) {
147824
- const file = state.program.getSourceFileByPath(path4);
147822
+ for (const path5 of arrayFrom(state.affectedFilesPendingEmit.keys()).sort(compareStringsCaseSensitive)) {
147823
+ if (tryAddToSet(seenFiles, path5)) {
147824
+ const file = state.program.getSourceFileByPath(path5);
147825
147825
  if (!file || !sourceFileMayBeEmitted(file, state.program)) continue;
147826
- const fileId = toFileId(path4), pendingEmit = state.affectedFilesPendingEmit.get(path4);
147826
+ const fileId = toFileId(path5), pendingEmit = state.affectedFilesPendingEmit.get(path5);
147827
147827
  affectedFilesPendingEmit = append(
147828
147828
  affectedFilesPendingEmit,
147829
147829
  pendingEmit === fullEmitForOptions ? fileId : (
@@ -147857,17 +147857,17 @@ ${lanes.join("\n")}
147857
147857
  version
147858
147858
  };
147859
147859
  return buildInfo;
147860
- function relativeToBuildInfoEnsuringAbsolutePath(path4) {
147861
- return relativeToBuildInfo(getNormalizedAbsolutePath(path4, currentDirectory));
147860
+ function relativeToBuildInfoEnsuringAbsolutePath(path5) {
147861
+ return relativeToBuildInfo(getNormalizedAbsolutePath(path5, currentDirectory));
147862
147862
  }
147863
- function relativeToBuildInfo(path4) {
147864
- return ensurePathIsNonModuleName(getRelativePathFromDirectory(buildInfoDirectory, path4, state.program.getCanonicalFileName));
147863
+ function relativeToBuildInfo(path5) {
147864
+ return ensurePathIsNonModuleName(getRelativePathFromDirectory(buildInfoDirectory, path5, state.program.getCanonicalFileName));
147865
147865
  }
147866
- function toFileId(path4) {
147867
- let fileId = fileNameToFileId.get(path4);
147866
+ function toFileId(path5) {
147867
+ let fileId = fileNameToFileId.get(path5);
147868
147868
  if (fileId === void 0) {
147869
- fileNames.push(relativeToBuildInfo(path4));
147870
- fileNameToFileId.set(path4, fileId = fileNames.length);
147869
+ fileNames.push(relativeToBuildInfo(path5));
147870
+ fileNameToFileId.set(path5, fileId = fileNames.length);
147871
147871
  }
147872
147872
  return fileId;
147873
147873
  }
@@ -147881,8 +147881,8 @@ ${lanes.join("\n")}
147881
147881
  }
147882
147882
  return fileIdListId;
147883
147883
  }
147884
- function tryAddRoot(path4, fileId) {
147885
- const file = state.program.getSourceFile(path4);
147884
+ function tryAddRoot(path5, fileId) {
147885
+ const file = state.program.getSourceFile(path5);
147886
147886
  if (!state.program.getFileIncludeReasons().get(file.path).some(
147887
147887
  (r) => r.kind === 0
147888
147888
  /* RootFile */
@@ -147899,10 +147899,10 @@ ${lanes.join("\n")}
147899
147899
  }
147900
147900
  function toResolvedRoot() {
147901
147901
  let result;
147902
- rootFileNames.forEach((path4) => {
147903
- const file = state.program.getSourceFileByPath(path4);
147904
- if (file && path4 !== file.resolvedPath) {
147905
- result = append(result, [toFileId(file.resolvedPath), toFileId(path4)]);
147902
+ rootFileNames.forEach((path5) => {
147903
+ const file = state.program.getSourceFileByPath(path5);
147904
+ if (file && path5 !== file.resolvedPath) {
147905
+ result = append(result, [toFileId(file.resolvedPath), toFileId(path5)]);
147906
147906
  }
147907
147907
  });
147908
147908
  return result;
@@ -148010,8 +148010,8 @@ ${lanes.join("\n")}
148010
148010
  function toChangeFileSet() {
148011
148011
  let changeFileSet;
148012
148012
  if (state.changedFilesSet.size) {
148013
- for (const path4 of arrayFrom(state.changedFilesSet.keys()).sort(compareStringsCaseSensitive)) {
148014
- changeFileSet = append(changeFileSet, toFileId(path4));
148013
+ for (const path5 of arrayFrom(state.changedFilesSet.keys()).sort(compareStringsCaseSensitive)) {
148014
+ changeFileSet = append(changeFileSet, toFileId(path5));
148015
148015
  }
148016
148016
  }
148017
148017
  return changeFileSet;
@@ -148510,8 +148510,8 @@ ${lanes.join("\n")}
148510
148510
  const changedFilesSet = new Set(map(buildInfo.changeFileSet, toFilePath));
148511
148511
  if (isIncrementalBundleEmitBuildInfo(buildInfo)) {
148512
148512
  buildInfo.fileInfos.forEach((fileInfo, index2) => {
148513
- const path4 = toFilePath(index2 + 1);
148514
- fileInfos.set(path4, isString(fileInfo) ? { version: fileInfo, signature: void 0, affectsGlobalScope: void 0, impliedFormat: void 0 } : fileInfo);
148513
+ const path5 = toFilePath(index2 + 1);
148514
+ fileInfos.set(path5, isString(fileInfo) ? { version: fileInfo, signature: void 0, affectsGlobalScope: void 0, impliedFormat: void 0 } : fileInfo);
148515
148515
  });
148516
148516
  state = {
148517
148517
  fileInfos,
@@ -148530,10 +148530,10 @@ ${lanes.join("\n")}
148530
148530
  filePathsSetList = (_b = buildInfo.fileIdsList) == null ? void 0 : _b.map((fileIds) => new Set(fileIds.map(toFilePath)));
148531
148531
  const emitSignatures = ((_c = buildInfo.options) == null ? void 0 : _c.composite) && !buildInfo.options.outFile ? /* @__PURE__ */ new Map() : void 0;
148532
148532
  buildInfo.fileInfos.forEach((fileInfo, index2) => {
148533
- const path4 = toFilePath(index2 + 1);
148533
+ const path5 = toFilePath(index2 + 1);
148534
148534
  const stateFileInfo = toBuilderStateFileInfoForMultiEmit(fileInfo);
148535
- fileInfos.set(path4, stateFileInfo);
148536
- if (emitSignatures && stateFileInfo.signature) emitSignatures.set(path4, stateFileInfo.signature);
148535
+ fileInfos.set(path5, stateFileInfo);
148536
+ if (emitSignatures && stateFileInfo.signature) emitSignatures.set(path5, stateFileInfo.signature);
148537
148537
  });
148538
148538
  (_d = buildInfo.emitSignatures) == null ? void 0 : _d.forEach((value) => {
148539
148539
  if (isNumber(value)) emitSignatures.delete(toFilePath(value));
@@ -148587,11 +148587,11 @@ ${lanes.join("\n")}
148587
148587
  close: noop,
148588
148588
  hasChangedEmitSignature: returnFalse
148589
148589
  };
148590
- function toPathInBuildInfoDirectory(path4) {
148591
- return toPath(path4, buildInfoDirectory, getCanonicalFileName);
148590
+ function toPathInBuildInfoDirectory(path5) {
148591
+ return toPath(path5, buildInfoDirectory, getCanonicalFileName);
148592
148592
  }
148593
- function toAbsolutePath(path4) {
148594
- return getNormalizedAbsolutePath(path4, buildInfoDirectory);
148593
+ function toAbsolutePath(path5) {
148594
+ return getNormalizedAbsolutePath(path5, buildInfoDirectory);
148595
148595
  }
148596
148596
  function toFilePath(fileId) {
148597
148597
  return filePaths[fileId - 1];
@@ -148630,30 +148630,30 @@ ${lanes.join("\n")}
148630
148630
  const roots = /* @__PURE__ */ new Map();
148631
148631
  const resolvedRoots = new Map(program2.resolvedRoot);
148632
148632
  program2.fileInfos.forEach((fileInfo, index2) => {
148633
- const path4 = toPath(program2.fileNames[index2], buildInfoDirectory, getCanonicalFileName);
148633
+ const path5 = toPath(program2.fileNames[index2], buildInfoDirectory, getCanonicalFileName);
148634
148634
  const version2 = isString(fileInfo) ? fileInfo : fileInfo.version;
148635
- fileInfos.set(path4, version2);
148635
+ fileInfos.set(path5, version2);
148636
148636
  if (rootIndex < program2.root.length) {
148637
148637
  const current = program2.root[rootIndex];
148638
148638
  const fileId = index2 + 1;
148639
148639
  if (isArray(current)) {
148640
148640
  if (current[0] <= fileId && fileId <= current[1]) {
148641
- addRoot(fileId, path4);
148641
+ addRoot(fileId, path5);
148642
148642
  if (current[1] === fileId) rootIndex++;
148643
148643
  }
148644
148644
  } else if (current === fileId) {
148645
- addRoot(fileId, path4);
148645
+ addRoot(fileId, path5);
148646
148646
  rootIndex++;
148647
148647
  }
148648
148648
  }
148649
148649
  });
148650
148650
  return { fileInfos, roots };
148651
- function addRoot(fileId, path4) {
148651
+ function addRoot(fileId, path5) {
148652
148652
  const root = resolvedRoots.get(fileId);
148653
148653
  if (root) {
148654
- roots.set(toPath(program2.fileNames[root - 1], buildInfoDirectory, getCanonicalFileName), path4);
148654
+ roots.set(toPath(program2.fileNames[root - 1], buildInfoDirectory, getCanonicalFileName), path5);
148655
148655
  } else {
148656
- roots.set(path4, void 0);
148656
+ roots.set(path5, void 0);
148657
148657
  }
148658
148658
  }
148659
148659
  }
@@ -148728,11 +148728,11 @@ ${lanes.join("\n")}
148728
148728
  newConfigFileParsingDiagnostics
148729
148729
  );
148730
148730
  }
148731
- function removeIgnoredPath(path4) {
148732
- if (endsWith(path4, "/node_modules/.staging")) {
148733
- return removeSuffix(path4, "/.staging");
148731
+ function removeIgnoredPath(path5) {
148732
+ if (endsWith(path5, "/node_modules/.staging")) {
148733
+ return removeSuffix(path5, "/.staging");
148734
148734
  }
148735
- return some(ignoredPaths, (searchPath) => path4.includes(searchPath)) ? void 0 : path4;
148735
+ return some(ignoredPaths, (searchPath) => path5.includes(searchPath)) ? void 0 : path5;
148736
148736
  }
148737
148737
  function perceivedOsRootLengthForWatching(pathComponents2, length2) {
148738
148738
  if (length2 <= 1) return 1;
@@ -148758,8 +148758,8 @@ ${lanes.join("\n")}
148758
148758
  const perceivedOsRootLength = perceivedOsRootLengthForWatching(pathComponents2, length2);
148759
148759
  return length2 > perceivedOsRootLength + 1;
148760
148760
  }
148761
- function canWatchDirectoryOrFilePath(path4) {
148762
- return canWatchDirectoryOrFile(getPathComponents(path4));
148761
+ function canWatchDirectoryOrFilePath(path5) {
148762
+ return canWatchDirectoryOrFile(getPathComponents(path5));
148763
148763
  }
148764
148764
  function canWatchAtTypes(atTypes) {
148765
148765
  return canWatchAffectedPackageJsonOrNodeModulesOfAtTypes(getDirectoryPath(atTypes));
@@ -149053,11 +149053,11 @@ ${lanes.join("\n")}
149053
149053
  filesWithChangedSetOfUnresolvedImports = void 0;
149054
149054
  return collected;
149055
149055
  }
149056
- function isFileWithInvalidatedNonRelativeUnresolvedImports(path4) {
149056
+ function isFileWithInvalidatedNonRelativeUnresolvedImports(path5) {
149057
149057
  if (!filesWithInvalidatedNonRelativeUnresolvedImports) {
149058
149058
  return false;
149059
149059
  }
149060
- const value = filesWithInvalidatedNonRelativeUnresolvedImports.get(path4);
149060
+ const value = filesWithInvalidatedNonRelativeUnresolvedImports.get(path5);
149061
149061
  return !!value && !!value.length;
149062
149062
  }
149063
149063
  function createHasInvalidatedResolutions(customHasInvalidatedResolutions, customHasInvalidatedLibResolutions) {
@@ -149065,7 +149065,7 @@ ${lanes.join("\n")}
149065
149065
  const collected = filesWithInvalidatedResolutions;
149066
149066
  filesWithInvalidatedResolutions = void 0;
149067
149067
  return {
149068
- hasInvalidatedResolutions: (path4) => customHasInvalidatedResolutions(path4) || allModuleAndTypeResolutionsAreInvalidated || !!(collected == null ? void 0 : collected.has(path4)) || isFileWithInvalidatedNonRelativeUnresolvedImports(path4),
149068
+ hasInvalidatedResolutions: (path5) => customHasInvalidatedResolutions(path5) || allModuleAndTypeResolutionsAreInvalidated || !!(collected == null ? void 0 : collected.has(path5)) || isFileWithInvalidatedNonRelativeUnresolvedImports(path5),
149069
149069
  hasInvalidatedLibResolutions: (libFileName) => {
149070
149070
  var _a;
149071
149071
  return customHasInvalidatedLibResolutions(libFileName) || !!((_a = resolvedLibraries == null ? void 0 : resolvedLibraries.get(libFileName)) == null ? void 0 : _a.isInvalidated);
@@ -149121,11 +149121,11 @@ ${lanes.join("\n")}
149121
149121
  if (expected) impliedFormatPackageJsons.set(newFile.resolvedPath, newFile.packageJsonLocations);
149122
149122
  else impliedFormatPackageJsons.delete(newFile.resolvedPath);
149123
149123
  });
149124
- impliedFormatPackageJsons.forEach((existing, path4) => {
149125
- const newFile = newProgram == null ? void 0 : newProgram.getSourceFileByPath(path4);
149126
- if (!newFile || newFile.resolvedPath !== path4) {
149124
+ impliedFormatPackageJsons.forEach((existing, path5) => {
149125
+ const newFile = newProgram == null ? void 0 : newProgram.getSourceFileByPath(path5);
149126
+ if (!newFile || newFile.resolvedPath !== path5) {
149127
149127
  existing.forEach((location) => fileWatchesOfAffectingLocations.get(location).files--);
149128
- impliedFormatPackageJsons.delete(path4);
149128
+ impliedFormatPackageJsons.delete(path5);
149129
149129
  }
149130
149130
  });
149131
149131
  }
@@ -149144,16 +149144,16 @@ ${lanes.join("\n")}
149144
149144
  packageDirWatchers.delete(packageDirPath);
149145
149145
  }
149146
149146
  }
149147
- function closeDirectoryWatchesOfFailedLookup(watcher, path4) {
149147
+ function closeDirectoryWatchesOfFailedLookup(watcher, path5) {
149148
149148
  if (watcher.refCount === 0) {
149149
- directoryWatchesOfFailedLookups.delete(path4);
149149
+ directoryWatchesOfFailedLookups.delete(path5);
149150
149150
  watcher.watcher.close();
149151
149151
  }
149152
149152
  }
149153
- function closeFileWatcherOfAffectingLocation(watcher, path4) {
149153
+ function closeFileWatcherOfAffectingLocation(watcher, path5) {
149154
149154
  var _a;
149155
149155
  if (watcher.files === 0 && watcher.resolutions === 0 && !((_a = watcher.symlinks) == null ? void 0 : _a.size)) {
149156
- fileWatchesOfAffectingLocations.delete(path4);
149156
+ fileWatchesOfAffectingLocations.delete(path5);
149157
149157
  watcher.watcher.close();
149158
149158
  }
149159
149159
  }
@@ -149172,10 +149172,10 @@ ${lanes.join("\n")}
149172
149172
  logChanges
149173
149173
  }) {
149174
149174
  var _a;
149175
- const path4 = resolutionHost.toPath(containingFile);
149176
- const resolutionsInFile = perFileCache.get(path4) || perFileCache.set(path4, createModeAwareCache()).get(path4);
149175
+ const path5 = resolutionHost.toPath(containingFile);
149176
+ const resolutionsInFile = perFileCache.get(path5) || perFileCache.set(path5, createModeAwareCache()).get(path5);
149177
149177
  const resolvedModules = [];
149178
- const hasInvalidatedNonRelativeUnresolvedImport = logChanges && isFileWithInvalidatedNonRelativeUnresolvedImports(path4);
149178
+ const hasInvalidatedNonRelativeUnresolvedImport = logChanges && isFileWithInvalidatedNonRelativeUnresolvedImports(path5);
149179
149179
  const program2 = resolutionHost.getCurrentProgram();
149180
149180
  const oldRedirect = program2 && ((_a = program2.getRedirectFromSourceFile(containingFile)) == null ? void 0 : _a.resolvedRef);
149181
149181
  const unmatchedRedirects = oldRedirect ? !redirectedReference || redirectedReference.sourceFile.path !== oldRedirect.sourceFile.path : !!redirectedReference;
@@ -149193,13 +149193,13 @@ ${lanes.join("\n")}
149193
149193
  }
149194
149194
  resolutionsInFile.set(name, mode, resolution);
149195
149195
  if (resolution !== existingResolution) {
149196
- watchFailedLookupLocationsOfExternalModuleResolutions(name, resolution, path4, getResolutionWithResolvedFileName, deferWatchingNonRelativeResolution);
149196
+ watchFailedLookupLocationsOfExternalModuleResolutions(name, resolution, path5, getResolutionWithResolvedFileName, deferWatchingNonRelativeResolution);
149197
149197
  if (existingResolution) {
149198
- stopWatchFailedLookupLocationOfResolution(existingResolution, path4, getResolutionWithResolvedFileName);
149198
+ stopWatchFailedLookupLocationOfResolution(existingResolution, path5, getResolutionWithResolvedFileName);
149199
149199
  }
149200
149200
  }
149201
149201
  if (logChanges && filesWithChangedSetOfUnresolvedImports && !resolutionIsEqualTo(existingResolution, resolution)) {
149202
- filesWithChangedSetOfUnresolvedImports.push(path4);
149202
+ filesWithChangedSetOfUnresolvedImports.push(path5);
149203
149203
  logChanges = false;
149204
149204
  }
149205
149205
  } else {
@@ -149230,7 +149230,7 @@ ${lanes.join("\n")}
149230
149230
  if (resolutionsInFile.size() !== seenNamesInFile.size()) {
149231
149231
  resolutionsInFile.forEach((resolution, name, mode) => {
149232
149232
  if (!seenNamesInFile.has(name, mode)) {
149233
- stopWatchFailedLookupLocationOfResolution(resolution, path4, getResolutionWithResolvedFileName);
149233
+ stopWatchFailedLookupLocationOfResolution(resolution, path5, getResolutionWithResolvedFileName);
149234
149234
  resolutionsInFile.delete(name, mode);
149235
149235
  }
149236
149236
  });
@@ -149304,18 +149304,18 @@ ${lanes.join("\n")}
149304
149304
  if (!resolution || resolution.isInvalidated) {
149305
149305
  const existingResolution = resolution;
149306
149306
  resolution = resolveLibrary(libraryName, resolveFrom, options, host, libraryResolutionCache);
149307
- const path4 = resolutionHost.toPath(resolveFrom);
149307
+ const path5 = resolutionHost.toPath(resolveFrom);
149308
149308
  watchFailedLookupLocationsOfExternalModuleResolutions(
149309
149309
  libraryName,
149310
149310
  resolution,
149311
- path4,
149311
+ path5,
149312
149312
  getResolvedModuleFromResolution,
149313
149313
  /*deferWatchingNonRelativeResolution*/
149314
149314
  false
149315
149315
  );
149316
149316
  resolvedLibraries.set(libFileName, resolution);
149317
149317
  if (existingResolution) {
149318
- stopWatchFailedLookupLocationOfResolution(existingResolution, path4, getResolvedModuleFromResolution);
149318
+ stopWatchFailedLookupLocationOfResolution(existingResolution, path5, getResolvedModuleFromResolution);
149319
149319
  }
149320
149320
  } else {
149321
149321
  if (isTraceEnabled(options, host)) {
@@ -149334,8 +149334,8 @@ ${lanes.join("\n")}
149334
149334
  }
149335
149335
  function resolveSingleModuleNameWithoutWatching(moduleName, containingFile) {
149336
149336
  var _a, _b;
149337
- const path4 = resolutionHost.toPath(containingFile);
149338
- const resolutionsInFile = resolvedModuleNames.get(path4);
149337
+ const path5 = resolutionHost.toPath(containingFile);
149338
+ const resolutionsInFile = resolvedModuleNames.get(path5);
149339
149339
  const resolution = resolutionsInFile == null ? void 0 : resolutionsInFile.get(
149340
149340
  moduleName,
149341
149341
  /*mode*/
@@ -149492,13 +149492,13 @@ ${lanes.join("\n")}
149492
149492
  (symlinkWatcher.symlinks ?? (symlinkWatcher.symlinks = /* @__PURE__ */ new Set())).add(affectingLocation);
149493
149493
  }
149494
149494
  }
149495
- function invalidateAffectingFileWatcher(path4, packageJsonMap) {
149495
+ function invalidateAffectingFileWatcher(path5, packageJsonMap) {
149496
149496
  var _a;
149497
- const watcher = fileWatchesOfAffectingLocations.get(path4);
149498
- if (watcher == null ? void 0 : watcher.resolutions) (affectingPathChecks ?? (affectingPathChecks = /* @__PURE__ */ new Set())).add(path4);
149499
- if (watcher == null ? void 0 : watcher.files) (affectingPathChecksForFile ?? (affectingPathChecksForFile = /* @__PURE__ */ new Set())).add(path4);
149497
+ const watcher = fileWatchesOfAffectingLocations.get(path5);
149498
+ if (watcher == null ? void 0 : watcher.resolutions) (affectingPathChecks ?? (affectingPathChecks = /* @__PURE__ */ new Set())).add(path5);
149499
+ if (watcher == null ? void 0 : watcher.files) (affectingPathChecksForFile ?? (affectingPathChecksForFile = /* @__PURE__ */ new Set())).add(path5);
149500
149500
  (_a = watcher == null ? void 0 : watcher.symlinks) == null ? void 0 : _a.forEach((path22) => invalidateAffectingFileWatcher(path22, packageJsonMap));
149501
- packageJsonMap == null ? void 0 : packageJsonMap.delete(resolutionHost.toPath(path4));
149501
+ packageJsonMap == null ? void 0 : packageJsonMap.delete(resolutionHost.toPath(path5));
149502
149502
  }
149503
149503
  function watchFailedLookupLocationOfNonRelativeModuleResolutions() {
149504
149504
  nonRelativeExternalModuleResolutions.forEach(watchFailedLookupLocationOfResolution);
@@ -149737,7 +149737,7 @@ ${lanes.join("\n")}
149737
149737
  function invalidatePackageJsonMap() {
149738
149738
  const packageJsonMap = moduleResolutionCache.getPackageJsonInfoCache().getInternalMap();
149739
149739
  if (packageJsonMap && (failedLookupChecks || startsWithPathChecks || isInDirectoryChecks)) {
149740
- packageJsonMap.forEach((_value, path4) => isInvalidatedFailedLookup(path4) ? packageJsonMap.delete(path4) : void 0);
149740
+ packageJsonMap.forEach((_value, path5) => isInvalidatedFailedLookup(path5) ? packageJsonMap.delete(path5) : void 0);
149741
149741
  }
149742
149742
  }
149743
149743
  function invalidateResolutionsOfFailedLookupLocations() {
@@ -150355,9 +150355,9 @@ ${lanes.join("\n")}
150355
150355
  getDefaultLibLocation: maybeBind(host, host.getDefaultLibLocation),
150356
150356
  getDefaultLibFileName: (options) => host.getDefaultLibFileName(options),
150357
150357
  writeFile: createWriteFileMeasuringIO(
150358
- (path4, data, writeByteOrderMark) => host.writeFile(path4, data, writeByteOrderMark),
150359
- (path4) => host.createDirectory(path4),
150360
- (path4) => host.directoryExists(path4)
150358
+ (path5, data, writeByteOrderMark) => host.writeFile(path5, data, writeByteOrderMark),
150359
+ (path5) => host.createDirectory(path5),
150360
+ (path5) => host.directoryExists(path5)
150361
150361
  ),
150362
150362
  getCurrentDirectory: memoize(() => host.getCurrentDirectory()),
150363
150363
  useCaseSensitiveFileNames: () => useCaseSensitiveFileNames2,
@@ -150428,16 +150428,16 @@ ${lanes.join("\n")}
150428
150428
  getCurrentDirectory: memoize(() => system.getCurrentDirectory()),
150429
150429
  getDefaultLibLocation,
150430
150430
  getDefaultLibFileName: (options) => combinePaths(getDefaultLibLocation(), getDefaultLibFileName(options)),
150431
- fileExists: (path4) => system.fileExists(path4),
150432
- readFile: (path4, encoding) => system.readFile(path4, encoding),
150433
- directoryExists: (path4) => system.directoryExists(path4),
150434
- getDirectories: (path4) => system.getDirectories(path4),
150435
- readDirectory: (path4, extensions, exclude, include, depth) => system.readDirectory(path4, extensions, exclude, include, depth),
150431
+ fileExists: (path5) => system.fileExists(path5),
150432
+ readFile: (path5, encoding) => system.readFile(path5, encoding),
150433
+ directoryExists: (path5) => system.directoryExists(path5),
150434
+ getDirectories: (path5) => system.getDirectories(path5),
150435
+ readDirectory: (path5, extensions, exclude, include, depth) => system.readDirectory(path5, extensions, exclude, include, depth),
150436
150436
  realpath: maybeBind(system, system.realpath),
150437
150437
  getEnvironmentVariable: maybeBind(system, system.getEnvironmentVariable),
150438
150438
  trace: (s) => system.write(s + system.newLine),
150439
- createDirectory: (path4) => system.createDirectory(path4),
150440
- writeFile: (path4, data, writeByteOrderMark) => system.writeFile(path4, data, writeByteOrderMark),
150439
+ createDirectory: (path5) => system.createDirectory(path5),
150440
+ writeFile: (path5, data, writeByteOrderMark) => system.writeFile(path5, data, writeByteOrderMark),
150441
150441
  createHash: maybeBind(system, system.createHash),
150442
150442
  createProgram: createProgram2 || createEmitAndSemanticDiagnosticsBuilderProgram,
150443
150443
  storeSignatureInfo: system.storeSignatureInfo,
@@ -150750,7 +150750,7 @@ ${lanes.join("\n")}
150750
150750
  originalWriteFile,
150751
150751
  readFileWithCache
150752
150752
  } = changeCompilerHostLikeToUseCache(compilerHost, toPath3);
150753
- if (isProgramUptoDate(getCurrentProgram(), rootFileNames, compilerOptions, (path4) => getSourceVersion(path4, readFileWithCache), (fileName) => compilerHost.fileExists(fileName), hasInvalidatedResolutions, hasInvalidatedLibResolutions, hasChangedAutomaticTypeDirectiveNames, getParsedCommandLine, projectReferences)) {
150753
+ if (isProgramUptoDate(getCurrentProgram(), rootFileNames, compilerOptions, (path5) => getSourceVersion(path5, readFileWithCache), (fileName) => compilerHost.fileExists(fileName), hasInvalidatedResolutions, hasInvalidatedLibResolutions, hasChangedAutomaticTypeDirectiveNames, getParsedCommandLine, projectReferences)) {
150754
150754
  if (hasChangedConfigFileParsingErrors) {
150755
150755
  if (reportFileChangeDetectedOnCreateProgram) {
150756
150756
  reportWatchDiagnostic(Diagnostics.File_change_detected_Starting_incremental_compilation);
@@ -150844,14 +150844,14 @@ ${lanes.join("\n")}
150844
150844
  return typeof hostSourceFile.version === "boolean";
150845
150845
  }
150846
150846
  function fileExists(fileName) {
150847
- const path4 = toPath3(fileName);
150848
- if (isFileMissingOnHost(sourceFilesCache.get(path4))) {
150847
+ const path5 = toPath3(fileName);
150848
+ if (isFileMissingOnHost(sourceFilesCache.get(path5))) {
150849
150849
  return false;
150850
150850
  }
150851
150851
  return directoryStructureHost.fileExists(fileName);
150852
150852
  }
150853
- function getVersionedSourceFileByPath(fileName, path4, languageVersionOrOptions, onError, shouldCreateNewSourceFile) {
150854
- const hostSourceFile = sourceFilesCache.get(path4);
150853
+ function getVersionedSourceFileByPath(fileName, path5, languageVersionOrOptions, onError, shouldCreateNewSourceFile) {
150854
+ const hostSourceFile = sourceFilesCache.get(path5);
150855
150855
  if (isFileMissingOnHost(hostSourceFile)) {
150856
150856
  return void 0;
150857
150857
  }
@@ -150863,41 +150863,41 @@ ${lanes.join("\n")}
150863
150863
  hostSourceFile.sourceFile = sourceFile;
150864
150864
  hostSourceFile.version = sourceFile.version;
150865
150865
  if (!hostSourceFile.fileWatcher) {
150866
- hostSourceFile.fileWatcher = watchFilePath(path4, fileName, onSourceFileChange, 250, watchOptions, WatchType.SourceFile);
150866
+ hostSourceFile.fileWatcher = watchFilePath(path5, fileName, onSourceFileChange, 250, watchOptions, WatchType.SourceFile);
150867
150867
  }
150868
150868
  } else {
150869
150869
  if (hostSourceFile.fileWatcher) {
150870
150870
  hostSourceFile.fileWatcher.close();
150871
150871
  }
150872
- sourceFilesCache.set(path4, false);
150872
+ sourceFilesCache.set(path5, false);
150873
150873
  }
150874
150874
  } else {
150875
150875
  if (sourceFile) {
150876
- const fileWatcher = watchFilePath(path4, fileName, onSourceFileChange, 250, watchOptions, WatchType.SourceFile);
150877
- sourceFilesCache.set(path4, { sourceFile, version: sourceFile.version, fileWatcher });
150876
+ const fileWatcher = watchFilePath(path5, fileName, onSourceFileChange, 250, watchOptions, WatchType.SourceFile);
150877
+ sourceFilesCache.set(path5, { sourceFile, version: sourceFile.version, fileWatcher });
150878
150878
  } else {
150879
- sourceFilesCache.set(path4, false);
150879
+ sourceFilesCache.set(path5, false);
150880
150880
  }
150881
150881
  }
150882
150882
  return sourceFile;
150883
150883
  }
150884
150884
  return hostSourceFile.sourceFile;
150885
150885
  }
150886
- function nextSourceFileVersion(path4) {
150887
- const hostSourceFile = sourceFilesCache.get(path4);
150886
+ function nextSourceFileVersion(path5) {
150887
+ const hostSourceFile = sourceFilesCache.get(path5);
150888
150888
  if (hostSourceFile !== void 0) {
150889
150889
  if (isFileMissingOnHost(hostSourceFile)) {
150890
- sourceFilesCache.set(path4, { version: false });
150890
+ sourceFilesCache.set(path5, { version: false });
150891
150891
  } else {
150892
150892
  hostSourceFile.version = false;
150893
150893
  }
150894
150894
  }
150895
150895
  }
150896
- function getSourceVersion(path4, readFileWithCache) {
150897
- const hostSourceFile = sourceFilesCache.get(path4);
150896
+ function getSourceVersion(path5, readFileWithCache) {
150897
+ const hostSourceFile = sourceFilesCache.get(path5);
150898
150898
  if (!hostSourceFile) return void 0;
150899
150899
  if (hostSourceFile.version) return hostSourceFile.version;
150900
- const text4 = readFileWithCache(path4);
150900
+ const text4 = readFileWithCache(path5);
150901
150901
  return text4 !== void 0 ? getSourceFileVersionAsHashFromText(compilerHost, text4) : void 0;
150902
150902
  }
150903
150903
  function onReleaseOldSourceFile(oldSourceFile, _oldOptions, hasSourceFileByPath) {
@@ -151076,28 +151076,28 @@ ${lanes.join("\n")}
151076
151076
  }
151077
151077
  function onReleaseParsedCommandLine(fileName) {
151078
151078
  var _a;
151079
- const path4 = toPath3(fileName);
151080
- const config = parsedConfigs == null ? void 0 : parsedConfigs.get(path4);
151079
+ const path5 = toPath3(fileName);
151080
+ const config = parsedConfigs == null ? void 0 : parsedConfigs.get(path5);
151081
151081
  if (!config) return;
151082
- parsedConfigs.delete(path4);
151082
+ parsedConfigs.delete(path5);
151083
151083
  if (config.watchedDirectories) clearMap(config.watchedDirectories, closeFileWatcherOf);
151084
151084
  (_a = config.watcher) == null ? void 0 : _a.close();
151085
- clearSharedExtendedConfigFileWatcher(path4, sharedExtendedConfigFileWatchers);
151085
+ clearSharedExtendedConfigFileWatcher(path5, sharedExtendedConfigFileWatchers);
151086
151086
  }
151087
- function watchFilePath(path4, file, callback, pollingInterval, options, watchType) {
151088
- return watchFile2(file, (fileName, eventKind) => callback(fileName, eventKind, path4), pollingInterval, options, watchType);
151087
+ function watchFilePath(path5, file, callback, pollingInterval, options, watchType) {
151088
+ return watchFile2(file, (fileName, eventKind) => callback(fileName, eventKind, path5), pollingInterval, options, watchType);
151089
151089
  }
151090
- function onSourceFileChange(fileName, eventKind, path4) {
151091
- updateCachedSystemWithFile(fileName, path4, eventKind);
151092
- if (eventKind === 2 && sourceFilesCache.has(path4)) {
151093
- resolutionCache.invalidateResolutionOfFile(path4);
151090
+ function onSourceFileChange(fileName, eventKind, path5) {
151091
+ updateCachedSystemWithFile(fileName, path5, eventKind);
151092
+ if (eventKind === 2 && sourceFilesCache.has(path5)) {
151093
+ resolutionCache.invalidateResolutionOfFile(path5);
151094
151094
  }
151095
- nextSourceFileVersion(path4);
151095
+ nextSourceFileVersion(path5);
151096
151096
  scheduleProgramUpdate();
151097
151097
  }
151098
- function updateCachedSystemWithFile(fileName, path4, eventKind) {
151098
+ function updateCachedSystemWithFile(fileName, path5, eventKind) {
151099
151099
  if (cachedDirectoryStructureHost) {
151100
- cachedDirectoryStructureHost.addOrDeleteFile(fileName, path4, eventKind);
151100
+ cachedDirectoryStructureHost.addOrDeleteFile(fileName, path5, eventKind);
151101
151101
  }
151102
151102
  }
151103
151103
  function watchMissingFilePath(missingFilePath, missingFileName) {
@@ -151318,9 +151318,9 @@ ${lanes.join("\n")}
151318
151318
  }
151319
151319
  function createSolutionBuilderHostBase(system, createProgram2, reportDiagnostic, reportSolutionBuilderStatus) {
151320
151320
  const host = createProgramHost(system, createProgram2);
151321
- host.getModifiedTime = system.getModifiedTime ? (path4) => system.getModifiedTime(path4) : returnUndefined;
151322
- host.setModifiedTime = system.setModifiedTime ? (path4, date) => system.setModifiedTime(path4, date) : noop;
151323
- host.deleteFile = system.deleteFile ? (path4) => system.deleteFile(path4) : noop;
151321
+ host.getModifiedTime = system.getModifiedTime ? (path5) => system.getModifiedTime(path5) : returnUndefined;
151322
+ host.setModifiedTime = system.setModifiedTime ? (path5, date) => system.setModifiedTime(path5, date) : noop;
151323
+ host.deleteFile = system.deleteFile ? (path5) => system.deleteFile(path5) : noop;
151324
151324
  host.reportDiagnostic = reportDiagnostic || createDiagnosticReporter(system);
151325
151325
  host.reportSolutionBuilderStatus = reportSolutionBuilderStatus || createBuilderStatusReporter(system);
151326
151326
  host.now = maybeBind(system, system.now);
@@ -151491,8 +151491,8 @@ ${lanes.join("\n")}
151491
151491
  }
151492
151492
  function toResolvedConfigFilePath(state, fileName) {
151493
151493
  const { resolvedConfigFilePaths } = state;
151494
- const path4 = resolvedConfigFilePaths.get(fileName);
151495
- if (path4 !== void 0) return path4;
151494
+ const path5 = resolvedConfigFilePaths.get(fileName);
151495
+ if (path5 !== void 0) return path5;
151496
151496
  const resolvedPath = toPath2(state, fileName);
151497
151497
  resolvedConfigFilePaths.set(fileName, resolvedPath);
151498
151498
  return resolvedPath;
@@ -151880,7 +151880,7 @@ ${lanes.join("\n")}
151880
151880
  void 0,
151881
151881
  (name, text4, writeByteOrderMark, onError, sourceFiles, data) => {
151882
151882
  var _a2;
151883
- const path4 = toPath2(state, name);
151883
+ const path5 = toPath2(state, name);
151884
151884
  emittedOutputs.set(toPath2(state, name), name);
151885
151885
  if (data == null ? void 0 : data.buildInfo) {
151886
151886
  now || (now = getCurrentTime(state.host));
@@ -151910,7 +151910,7 @@ ${lanes.join("\n")}
151910
151910
  );
151911
151911
  if (data == null ? void 0 : data.differsOnlyInMap) state.host.setModifiedTime(name, modifiedTime);
151912
151912
  else if (!isIncremental && state.watch) {
151913
- (outputTimeStampMap || (outputTimeStampMap = getOutputTimeStampMap(state, projectPath))).set(path4, now || (now = getCurrentTime(state.host)));
151913
+ (outputTimeStampMap || (outputTimeStampMap = getOutputTimeStampMap(state, projectPath))).set(path5, now || (now = getCurrentTime(state.host)));
151914
151914
  }
151915
151915
  },
151916
151916
  cancellationToken,
@@ -152094,8 +152094,8 @@ ${lanes.join("\n")}
152094
152094
  return !!value.watcher;
152095
152095
  }
152096
152096
  function getModifiedTime2(state, fileName) {
152097
- const path4 = toPath2(state, fileName);
152098
- const existing = state.filesWatched.get(path4);
152097
+ const path5 = toPath2(state, fileName);
152098
+ const existing = state.filesWatched.get(path5);
152099
152099
  if (state.watch && !!existing) {
152100
152100
  if (!isFileWatcherWithModifiedTime(existing)) return existing;
152101
152101
  if (existing.modifiedTime) return existing.modifiedTime;
@@ -152103,20 +152103,20 @@ ${lanes.join("\n")}
152103
152103
  const result = getModifiedTime(state.host, fileName);
152104
152104
  if (state.watch) {
152105
152105
  if (existing) existing.modifiedTime = result;
152106
- else state.filesWatched.set(path4, result);
152106
+ else state.filesWatched.set(path5, result);
152107
152107
  }
152108
152108
  return result;
152109
152109
  }
152110
152110
  function watchFile(state, file, callback, pollingInterval, options, watchType, project) {
152111
- const path4 = toPath2(state, file);
152112
- const existing = state.filesWatched.get(path4);
152111
+ const path5 = toPath2(state, file);
152112
+ const existing = state.filesWatched.get(path5);
152113
152113
  if (existing && isFileWatcherWithModifiedTime(existing)) {
152114
152114
  existing.callbacks.push(callback);
152115
152115
  } else {
152116
152116
  const watcher = state.watchFile(
152117
152117
  file,
152118
152118
  (fileName, eventKind, modifiedTime) => {
152119
- const existing2 = Debug.checkDefined(state.filesWatched.get(path4));
152119
+ const existing2 = Debug.checkDefined(state.filesWatched.get(path5));
152120
152120
  Debug.assert(isFileWatcherWithModifiedTime(existing2));
152121
152121
  existing2.modifiedTime = modifiedTime;
152122
152122
  existing2.callbacks.forEach((cb) => cb(fileName, eventKind, modifiedTime));
@@ -152126,14 +152126,14 @@ ${lanes.join("\n")}
152126
152126
  watchType,
152127
152127
  project
152128
152128
  );
152129
- state.filesWatched.set(path4, { callbacks: [callback], watcher, modifiedTime: existing });
152129
+ state.filesWatched.set(path5, { callbacks: [callback], watcher, modifiedTime: existing });
152130
152130
  }
152131
152131
  return {
152132
152132
  close: () => {
152133
- const existing2 = Debug.checkDefined(state.filesWatched.get(path4));
152133
+ const existing2 = Debug.checkDefined(state.filesWatched.get(path5));
152134
152134
  Debug.assert(isFileWatcherWithModifiedTime(existing2));
152135
152135
  if (existing2.callbacks.length === 1) {
152136
- state.filesWatched.delete(path4);
152136
+ state.filesWatched.delete(path5);
152137
152137
  closeFileWatcherOf(existing2);
152138
152138
  } else {
152139
152139
  unorderedRemoveItem(existing2.callbacks, callback);
@@ -152148,19 +152148,19 @@ ${lanes.join("\n")}
152148
152148
  return result;
152149
152149
  }
152150
152150
  function getBuildInfoCacheEntry(state, buildInfoPath, resolvedConfigPath) {
152151
- const path4 = toPath2(state, buildInfoPath);
152151
+ const path5 = toPath2(state, buildInfoPath);
152152
152152
  const existing = state.buildInfoCache.get(resolvedConfigPath);
152153
- return (existing == null ? void 0 : existing.path) === path4 ? existing : void 0;
152153
+ return (existing == null ? void 0 : existing.path) === path5 ? existing : void 0;
152154
152154
  }
152155
152155
  function getBuildInfo3(state, buildInfoPath, resolvedConfigPath, modifiedTime) {
152156
- const path4 = toPath2(state, buildInfoPath);
152156
+ const path5 = toPath2(state, buildInfoPath);
152157
152157
  const existing = state.buildInfoCache.get(resolvedConfigPath);
152158
- if (existing !== void 0 && existing.path === path4) {
152158
+ if (existing !== void 0 && existing.path === path5) {
152159
152159
  return existing.buildInfo || void 0;
152160
152160
  }
152161
152161
  const value = state.readFileWithCache(buildInfoPath);
152162
152162
  const buildInfo = value ? getBuildInfo(buildInfoPath, value) : void 0;
152163
- state.buildInfoCache.set(resolvedConfigPath, { path: path4, buildInfo: buildInfo || false, modifiedTime: modifiedTime || missingFileModifiedTime });
152163
+ state.buildInfoCache.set(resolvedConfigPath, { path: path5, buildInfo: buildInfo || false, modifiedTime: modifiedTime || missingFileModifiedTime });
152164
152164
  return buildInfo;
152165
152165
  }
152166
152166
  function checkConfigFileUpToDateStatus(state, configFile, oldestOutputFileTime, oldestOutputFileName) {
@@ -152341,11 +152341,11 @@ ${lanes.join("\n")}
152341
152341
  const outputTimeStampMap = getOutputTimeStampMap(state, resolvedPath);
152342
152342
  for (const output of outputs) {
152343
152343
  if (output === buildInfoPath) continue;
152344
- const path4 = toPath2(state, output);
152345
- let outputTime = outputTimeStampMap == null ? void 0 : outputTimeStampMap.get(path4);
152344
+ const path5 = toPath2(state, output);
152345
+ let outputTime = outputTimeStampMap == null ? void 0 : outputTimeStampMap.get(path5);
152346
152346
  if (!outputTime) {
152347
152347
  outputTime = getModifiedTime(state.host, output);
152348
- outputTimeStampMap == null ? void 0 : outputTimeStampMap.set(path4, outputTime);
152348
+ outputTimeStampMap == null ? void 0 : outputTimeStampMap.set(path5, outputTime);
152349
152349
  }
152350
152350
  if (outputTime === missingFileModifiedTime) {
152351
152351
  return {
@@ -152399,7 +152399,7 @@ ${lanes.join("\n")}
152399
152399
  const packageJsonLookups = state.lastCachedPackageJsonLookups.get(resolvedPath);
152400
152400
  const dependentPackageFileStatus = packageJsonLookups && forEachKey(
152401
152401
  packageJsonLookups,
152402
- (path4) => checkConfigFileUpToDateStatus(state, path4, oldestOutputFileTime, oldestOutputFileName)
152402
+ (path5) => checkConfigFileUpToDateStatus(state, path5, oldestOutputFileTime, oldestOutputFileName)
152403
152403
  );
152404
152404
  if (dependentPackageFileStatus) return dependentPackageFileStatus;
152405
152405
  return {
@@ -152449,8 +152449,8 @@ ${lanes.join("\n")}
152449
152449
  if (!skipOutputs || outputs.length !== skipOutputs.size) {
152450
152450
  let reportVerbose = !!state.options.verbose;
152451
152451
  for (const file of outputs) {
152452
- const path4 = toPath2(state, file);
152453
- if (skipOutputs == null ? void 0 : skipOutputs.has(path4)) continue;
152452
+ const path5 = toPath2(state, file);
152453
+ if (skipOutputs == null ? void 0 : skipOutputs.has(path5)) continue;
152454
152454
  if (reportVerbose) {
152455
152455
  reportVerbose = false;
152456
152456
  reportStatus(state, verboseMessage, proj.options.configFilePath);
@@ -152458,8 +152458,8 @@ ${lanes.join("\n")}
152458
152458
  host.setModifiedTime(file, now || (now = getCurrentTime(state.host)));
152459
152459
  if (file === buildInfoPath) getBuildInfoCacheEntry(state, buildInfoPath, projectPath).modifiedTime = now;
152460
152460
  else if (outputTimeStampMap) {
152461
- outputTimeStampMap.set(path4, now);
152462
- modifiedOutputs.add(path4);
152461
+ outputTimeStampMap.set(path5, now);
152462
+ modifiedOutputs.add(path5);
152463
152463
  }
152464
152464
  }
152465
152465
  }
@@ -152887,8 +152887,8 @@ ${lanes.join("\n")}
152887
152887
  close: () => stopWatching(state)
152888
152888
  };
152889
152889
  }
152890
- function relName(state, path4) {
152891
- return convertToRelativePath(path4, state.compilerHost.getCurrentDirectory(), state.compilerHost.getCanonicalFileName);
152890
+ function relName(state, path5) {
152891
+ return convertToRelativePath(path5, state.compilerHost.getCurrentDirectory(), state.compilerHost.getCanonicalFileName);
152892
152892
  }
152893
152893
  function reportStatus(state, message, ...args) {
152894
152894
  state.host.reportSolutionBuilderStatus(createCompilerDiagnostic(message, ...args));
@@ -153107,13 +153107,13 @@ ${lanes.join("\n")}
153107
153107
  } else if (file.isDeclarationFile) {
153108
153108
  return "Definitions";
153109
153109
  }
153110
- const path4 = file.path;
153111
- if (fileExtensionIsOneOf(path4, supportedTSExtensionsFlat)) {
153110
+ const path5 = file.path;
153111
+ if (fileExtensionIsOneOf(path5, supportedTSExtensionsFlat)) {
153112
153112
  return "TypeScript";
153113
- } else if (fileExtensionIsOneOf(path4, supportedJSExtensionsFlat)) {
153113
+ } else if (fileExtensionIsOneOf(path5, supportedJSExtensionsFlat)) {
153114
153114
  return "JavaScript";
153115
153115
  } else if (fileExtensionIs(
153116
- path4,
153116
+ path5,
153117
153117
  ".json"
153118
153118
  /* Json */
153119
153119
  )) {
@@ -153725,7 +153725,7 @@ ${lanes.join("\n")}
153725
153725
  );
153726
153726
  }
153727
153727
  }
153728
- const commandLine = parseCommandLine(commandLineArgs, (path4) => system.readFile(path4));
153728
+ const commandLine = parseCommandLine(commandLineArgs, (path5) => system.readFile(path5));
153729
153729
  if (commandLine.options.generateCpuProfile && system.enableCPUProfiler) {
153730
153730
  system.enableCPUProfiler(commandLine.options.generateCpuProfile, () => executeCommandLineWorker(
153731
153731
  system,
@@ -155601,12 +155601,12 @@ ${lanes.join("\n")}
155601
155601
  return nodeCoreModules.has(moduleName) ? "node" : moduleName;
155602
155602
  }
155603
155603
  function loadSafeList(host, safeListPath) {
155604
- const result = readConfigFile(safeListPath, (path4) => host.readFile(path4));
155604
+ const result = readConfigFile(safeListPath, (path5) => host.readFile(path5));
155605
155605
  return new Map(Object.entries(result.config));
155606
155606
  }
155607
155607
  function loadTypesMap(host, typesMapPath) {
155608
155608
  var _a;
155609
- const result = readConfigFile(typesMapPath, (path4) => host.readFile(path4));
155609
+ const result = readConfigFile(typesMapPath, (path5) => host.readFile(path5));
155610
155610
  if ((_a = result.config) == null ? void 0 : _a.simpleMap) {
155611
155611
  return new Map(Object.entries(result.config.simpleMap));
155612
155612
  }
@@ -155618,9 +155618,9 @@ ${lanes.join("\n")}
155618
155618
  }
155619
155619
  const inferredTypings = /* @__PURE__ */ new Map();
155620
155620
  fileNames = mapDefined(fileNames, (fileName) => {
155621
- const path4 = normalizePath(fileName);
155622
- if (hasJSFileExtension(path4)) {
155623
- return path4;
155621
+ const path5 = normalizePath(fileName);
155622
+ if (hasJSFileExtension(path5)) {
155623
+ return path5;
155624
155624
  }
155625
155625
  });
155626
155626
  const filesToWatch = [];
@@ -155682,7 +155682,7 @@ ${lanes.join("\n")}
155682
155682
  let manifestTypingNames;
155683
155683
  if (host.fileExists(manifestPath)) {
155684
155684
  filesToWatch2.push(manifestPath);
155685
- manifest = readConfigFile(manifestPath, (path4) => host.readFile(path4)).config;
155685
+ manifest = readConfigFile(manifestPath, (path5) => host.readFile(path5)).config;
155686
155686
  manifestTypingNames = flatMap([manifest.dependencies, manifest.devDependencies, manifest.optionalDependencies, manifest.peerDependencies], getOwnKeys);
155687
155687
  addInferredTypings(manifestTypingNames, `Typing names in '${manifestPath}' dependencies`);
155688
155688
  }
@@ -155716,7 +155716,7 @@ ${lanes.join("\n")}
155716
155716
  if (log) log(`Searching for typing names in ${packagesFolderPath}; all files: ${JSON.stringify(dependencyManifestNames)}`);
155717
155717
  for (const manifestPath2 of dependencyManifestNames) {
155718
155718
  const normalizedFileName = normalizePath(manifestPath2);
155719
- const result2 = readConfigFile(normalizedFileName, (path4) => host.readFile(path4));
155719
+ const result2 = readConfigFile(normalizedFileName, (path5) => host.readFile(path5));
155720
155720
  const manifest2 = result2.config;
155721
155721
  if (!manifest2.name) {
155722
155722
  continue;
@@ -158496,14 +158496,14 @@ ${lanes.join("\n")}
158496
158496
  function tryGetDirectories(host, directoryName) {
158497
158497
  return tryIOAndConsumeErrors(host, host.getDirectories, directoryName) || [];
158498
158498
  }
158499
- function tryReadDirectory(host, path4, extensions, exclude, include) {
158500
- return tryIOAndConsumeErrors(host, host.readDirectory, path4, extensions, exclude, include) || emptyArray;
158499
+ function tryReadDirectory(host, path5, extensions, exclude, include) {
158500
+ return tryIOAndConsumeErrors(host, host.readDirectory, path5, extensions, exclude, include) || emptyArray;
158501
158501
  }
158502
- function tryFileExists(host, path4) {
158503
- return tryIOAndConsumeErrors(host, host.fileExists, path4);
158502
+ function tryFileExists(host, path5) {
158503
+ return tryIOAndConsumeErrors(host, host.fileExists, path5);
158504
158504
  }
158505
- function tryDirectoryExists(host, path4) {
158506
- return tryAndIgnoreErrors(() => directoryProbablyExists(path4, host)) || false;
158505
+ function tryDirectoryExists(host, path5) {
158506
+ return tryAndIgnoreErrors(() => directoryProbablyExists(path5, host)) || false;
158507
158507
  }
158508
158508
  function tryAndIgnoreErrors(cb) {
158509
158509
  try {
@@ -159345,13 +159345,13 @@ ${lanes.join("\n")}
159345
159345
  function getIsExcluded(excludePatterns, host) {
159346
159346
  var _a;
159347
159347
  const realpathsWithSymlinks = (_a = host.getSymlinkCache) == null ? void 0 : _a.call(host).getSymlinkedDirectoriesByRealpath();
159348
- return ({ fileName, path: path4 }) => {
159348
+ return ({ fileName, path: path5 }) => {
159349
159349
  if (excludePatterns.some((p9) => p9.test(fileName))) return true;
159350
159350
  if ((realpathsWithSymlinks == null ? void 0 : realpathsWithSymlinks.size) && pathContainsNodeModules(fileName)) {
159351
159351
  let dir = getDirectoryPath(fileName);
159352
159352
  return forEachAncestorDirectoryStoppingAtGlobalCache(
159353
159353
  host,
159354
- getDirectoryPath(path4),
159354
+ getDirectoryPath(path5),
159355
159355
  (dirPath) => {
159356
159356
  const symlinks = realpathsWithSymlinks.get(ensureTrailingDirectorySeparator(dirPath));
159357
159357
  if (symlinks) {
@@ -161007,14 +161007,14 @@ ${lanes.join("\n")}
161007
161007
  return settingsOrHost;
161008
161008
  }
161009
161009
  function acquireDocument(fileName, compilationSettings, scriptSnapshot, version2, scriptKind, languageVersionOrOptions) {
161010
- const path4 = toPath(fileName, currentDirectory, getCanonicalFileName);
161010
+ const path5 = toPath(fileName, currentDirectory, getCanonicalFileName);
161011
161011
  const key = getKeyForCompilationSettings(getCompilationSettings(compilationSettings));
161012
- return acquireDocumentWithKey(fileName, path4, compilationSettings, key, scriptSnapshot, version2, scriptKind, languageVersionOrOptions);
161012
+ return acquireDocumentWithKey(fileName, path5, compilationSettings, key, scriptSnapshot, version2, scriptKind, languageVersionOrOptions);
161013
161013
  }
161014
- function acquireDocumentWithKey(fileName, path4, compilationSettings, key, scriptSnapshot, version2, scriptKind, languageVersionOrOptions) {
161014
+ function acquireDocumentWithKey(fileName, path5, compilationSettings, key, scriptSnapshot, version2, scriptKind, languageVersionOrOptions) {
161015
161015
  return acquireOrUpdateDocument(
161016
161016
  fileName,
161017
- path4,
161017
+ path5,
161018
161018
  compilationSettings,
161019
161019
  key,
161020
161020
  scriptSnapshot,
@@ -161026,14 +161026,14 @@ ${lanes.join("\n")}
161026
161026
  );
161027
161027
  }
161028
161028
  function updateDocument(fileName, compilationSettings, scriptSnapshot, version2, scriptKind, languageVersionOrOptions) {
161029
- const path4 = toPath(fileName, currentDirectory, getCanonicalFileName);
161029
+ const path5 = toPath(fileName, currentDirectory, getCanonicalFileName);
161030
161030
  const key = getKeyForCompilationSettings(getCompilationSettings(compilationSettings));
161031
- return updateDocumentWithKey(fileName, path4, compilationSettings, key, scriptSnapshot, version2, scriptKind, languageVersionOrOptions);
161031
+ return updateDocumentWithKey(fileName, path5, compilationSettings, key, scriptSnapshot, version2, scriptKind, languageVersionOrOptions);
161032
161032
  }
161033
- function updateDocumentWithKey(fileName, path4, compilationSettings, key, scriptSnapshot, version2, scriptKind, languageVersionOrOptions) {
161033
+ function updateDocumentWithKey(fileName, path5, compilationSettings, key, scriptSnapshot, version2, scriptKind, languageVersionOrOptions) {
161034
161034
  return acquireOrUpdateDocument(
161035
161035
  fileName,
161036
- path4,
161036
+ path5,
161037
161037
  getCompilationSettings(compilationSettings),
161038
161038
  key,
161039
161039
  scriptSnapshot,
@@ -161049,7 +161049,7 @@ ${lanes.join("\n")}
161049
161049
  Debug.assert(scriptKind === void 0 || !entry || entry.sourceFile.scriptKind === scriptKind, `Script kind should match provided ScriptKind:${scriptKind} and sourceFile.scriptKind: ${entry == null ? void 0 : entry.sourceFile.scriptKind}, !entry: ${!entry}`);
161050
161050
  return entry;
161051
161051
  }
161052
- function acquireOrUpdateDocument(fileName, path4, compilationSettingsOrHost, key, scriptSnapshot, version2, acquiring, scriptKind, languageVersionOrOptions) {
161052
+ function acquireOrUpdateDocument(fileName, path5, compilationSettingsOrHost, key, scriptSnapshot, version2, acquiring, scriptKind, languageVersionOrOptions) {
161053
161053
  var _a, _b, _c, _d;
161054
161054
  scriptKind = ensureScriptKind(fileName, scriptKind);
161055
161055
  const compilationSettings = getCompilationSettings(compilationSettingsOrHost);
@@ -161057,7 +161057,7 @@ ${lanes.join("\n")}
161057
161057
  const scriptTarget = scriptKind === 6 ? 100 : getEmitScriptTarget(compilationSettings);
161058
161058
  const sourceFileOptions = typeof languageVersionOrOptions === "object" ? languageVersionOrOptions : {
161059
161059
  languageVersion: scriptTarget,
161060
- impliedNodeFormat: host && getImpliedNodeFormatForFile(path4, (_d = (_c = (_b = (_a = host.getCompilerHost) == null ? void 0 : _a.call(host)) == null ? void 0 : _b.getModuleResolutionCache) == null ? void 0 : _c.call(_b)) == null ? void 0 : _d.getPackageJsonInfoCache(), host, compilationSettings),
161060
+ impliedNodeFormat: host && getImpliedNodeFormatForFile(path5, (_d = (_c = (_b = (_a = host.getCompilerHost) == null ? void 0 : _a.call(host)) == null ? void 0 : _b.getModuleResolutionCache) == null ? void 0 : _c.call(_b)) == null ? void 0 : _d.getPackageJsonInfoCache(), host, compilationSettings),
161061
161061
  setExternalModuleIndicator: getSetExternalModuleIndicator(compilationSettings),
161062
161062
  jsDocParsingMode
161063
161063
  };
@@ -161070,15 +161070,15 @@ ${lanes.join("\n")}
161070
161070
  if (buckets.size > oldBucketCount) {
161071
161071
  tracing.instant(tracing.Phase.Session, "createdDocumentRegistryBucket", { configFilePath: compilationSettings.configFilePath, key: keyWithMode });
161072
161072
  }
161073
- const otherBucketKey = !isDeclarationFileName(path4) && forEachEntry(buckets, (bucket2, bucketKey) => bucketKey !== keyWithMode && bucket2.has(path4) && bucketKey);
161073
+ const otherBucketKey = !isDeclarationFileName(path5) && forEachEntry(buckets, (bucket2, bucketKey) => bucketKey !== keyWithMode && bucket2.has(path5) && bucketKey);
161074
161074
  if (otherBucketKey) {
161075
- tracing.instant(tracing.Phase.Session, "documentRegistryBucketOverlap", { path: path4, key1: otherBucketKey, key2: keyWithMode });
161075
+ tracing.instant(tracing.Phase.Session, "documentRegistryBucketOverlap", { path: path5, key1: otherBucketKey, key2: keyWithMode });
161076
161076
  }
161077
161077
  }
161078
- const bucketEntry = bucket.get(path4);
161078
+ const bucketEntry = bucket.get(path5);
161079
161079
  let entry = bucketEntry && getDocumentRegistryEntry(bucketEntry, scriptKind);
161080
161080
  if (!entry && externalCache) {
161081
- const sourceFile = externalCache.getDocument(keyWithMode, path4);
161081
+ const sourceFile = externalCache.getDocument(keyWithMode, path5);
161082
161082
  if (sourceFile && sourceFile.scriptKind === scriptKind && sourceFile.text === getSnapshotText(scriptSnapshot)) {
161083
161083
  Debug.assert(acquiring);
161084
161084
  entry = {
@@ -161099,7 +161099,7 @@ ${lanes.join("\n")}
161099
161099
  scriptKind
161100
161100
  );
161101
161101
  if (externalCache) {
161102
- externalCache.setDocument(keyWithMode, path4, sourceFile);
161102
+ externalCache.setDocument(keyWithMode, path5, sourceFile);
161103
161103
  }
161104
161104
  entry = {
161105
161105
  sourceFile,
@@ -161110,7 +161110,7 @@ ${lanes.join("\n")}
161110
161110
  if (entry.sourceFile.version !== version2) {
161111
161111
  entry.sourceFile = updateLanguageServiceSourceFile(entry.sourceFile, scriptSnapshot, version2, scriptSnapshot.getChangeRange(entry.sourceFile.scriptSnapshot));
161112
161112
  if (externalCache) {
161113
- externalCache.setDocument(keyWithMode, path4, entry.sourceFile);
161113
+ externalCache.setDocument(keyWithMode, path5, entry.sourceFile);
161114
161114
  }
161115
161115
  }
161116
161116
  if (acquiring) {
@@ -161121,35 +161121,35 @@ ${lanes.join("\n")}
161121
161121
  return entry.sourceFile;
161122
161122
  function setBucketEntry() {
161123
161123
  if (!bucketEntry) {
161124
- bucket.set(path4, entry);
161124
+ bucket.set(path5, entry);
161125
161125
  } else if (isDocumentRegistryEntry(bucketEntry)) {
161126
161126
  const scriptKindMap = /* @__PURE__ */ new Map();
161127
161127
  scriptKindMap.set(bucketEntry.sourceFile.scriptKind, bucketEntry);
161128
161128
  scriptKindMap.set(scriptKind, entry);
161129
- bucket.set(path4, scriptKindMap);
161129
+ bucket.set(path5, scriptKindMap);
161130
161130
  } else {
161131
161131
  bucketEntry.set(scriptKind, entry);
161132
161132
  }
161133
161133
  }
161134
161134
  }
161135
161135
  function releaseDocument(fileName, compilationSettings, scriptKind, impliedNodeFormat) {
161136
- const path4 = toPath(fileName, currentDirectory, getCanonicalFileName);
161136
+ const path5 = toPath(fileName, currentDirectory, getCanonicalFileName);
161137
161137
  const key = getKeyForCompilationSettings(compilationSettings);
161138
- return releaseDocumentWithKey(path4, key, scriptKind, impliedNodeFormat);
161138
+ return releaseDocumentWithKey(path5, key, scriptKind, impliedNodeFormat);
161139
161139
  }
161140
- function releaseDocumentWithKey(path4, key, scriptKind, impliedNodeFormat) {
161140
+ function releaseDocumentWithKey(path5, key, scriptKind, impliedNodeFormat) {
161141
161141
  const bucket = Debug.checkDefined(buckets.get(getDocumentRegistryBucketKeyWithMode(key, impliedNodeFormat)));
161142
- const bucketEntry = bucket.get(path4);
161142
+ const bucketEntry = bucket.get(path5);
161143
161143
  const entry = getDocumentRegistryEntry(bucketEntry, scriptKind);
161144
161144
  entry.languageServiceRefCount--;
161145
161145
  Debug.assert(entry.languageServiceRefCount >= 0);
161146
161146
  if (entry.languageServiceRefCount === 0) {
161147
161147
  if (isDocumentRegistryEntry(bucketEntry)) {
161148
- bucket.delete(path4);
161148
+ bucket.delete(path5);
161149
161149
  } else {
161150
161150
  bucketEntry.delete(scriptKind);
161151
161151
  if (bucketEntry.size === 1) {
161152
- bucket.set(path4, firstDefinedIterator(bucketEntry.values(), identity));
161152
+ bucket.set(path5, firstDefinedIterator(bucketEntry.values(), identity));
161153
161153
  }
161154
161154
  }
161155
161155
  }
@@ -161185,10 +161185,10 @@ ${lanes.join("\n")}
161185
161185
  }
161186
161186
  function getPathUpdater(oldFileOrDirPath, newFileOrDirPath, getCanonicalFileName, sourceMapper) {
161187
161187
  const canonicalOldPath = getCanonicalFileName(oldFileOrDirPath);
161188
- return (path4) => {
161189
- const originalPath = sourceMapper && sourceMapper.tryGetSourcePosition({ fileName: path4, pos: 0 });
161190
- const updatedPath = getUpdatedPath(originalPath ? originalPath.fileName : path4);
161191
- return originalPath ? updatedPath === void 0 ? void 0 : makeCorrespondingRelativeChange(originalPath.fileName, updatedPath, path4, getCanonicalFileName) : updatedPath;
161188
+ return (path5) => {
161189
+ const originalPath = sourceMapper && sourceMapper.tryGetSourcePosition({ fileName: path5, pos: 0 });
161190
+ const updatedPath = getUpdatedPath(originalPath ? originalPath.fileName : path5);
161191
+ return originalPath ? updatedPath === void 0 ? void 0 : makeCorrespondingRelativeChange(originalPath.fileName, updatedPath, path5, getCanonicalFileName) : updatedPath;
161192
161192
  };
161193
161193
  function getUpdatedPath(pathToUpdate) {
161194
161194
  if (getCanonicalFileName(pathToUpdate) === canonicalOldPath) return newFileOrDirPath;
@@ -161264,10 +161264,10 @@ ${lanes.join("\n")}
161264
161264
  }
161265
161265
  return false;
161266
161266
  }
161267
- function relativePath(path4) {
161267
+ function relativePath(path5) {
161268
161268
  return getRelativePathFromDirectory(
161269
161269
  configDir,
161270
- path4,
161270
+ path5,
161271
161271
  /*ignoreCase*/
161272
161272
  !useCaseSensitiveFileNames2
161273
161273
  );
@@ -162075,8 +162075,8 @@ ${lanes.join("\n")}
162075
162075
  return toPath(fileName, currentDirectory, getCanonicalFileName);
162076
162076
  }
162077
162077
  function getDocumentPositionMapper2(generatedFileName, sourceFileName) {
162078
- const path4 = toPath3(generatedFileName);
162079
- const value = documentPositionMappers.get(path4);
162078
+ const path5 = toPath3(generatedFileName);
162079
+ const value = documentPositionMappers.get(path5);
162080
162080
  if (value) return value;
162081
162081
  let mapper;
162082
162082
  if (host.getDocumentPositionMapper) {
@@ -162090,7 +162090,7 @@ ${lanes.join("\n")}
162090
162090
  (f) => !host.fileExists || host.fileExists(f) ? host.readFile(f) : void 0
162091
162091
  );
162092
162092
  }
162093
- documentPositionMappers.set(path4, mapper || identitySourceMapConsumer);
162093
+ documentPositionMappers.set(path5, mapper || identitySourceMapConsumer);
162094
162094
  return mapper || identitySourceMapConsumer;
162095
162095
  }
162096
162096
  function tryGetSourcePosition(info) {
@@ -162118,21 +162118,21 @@ ${lanes.join("\n")}
162118
162118
  function getSourceFile(fileName) {
162119
162119
  const program2 = host.getProgram();
162120
162120
  if (!program2) return void 0;
162121
- const path4 = toPath3(fileName);
162122
- const file = program2.getSourceFileByPath(path4);
162123
- return file && file.resolvedPath === path4 ? file : void 0;
162121
+ const path5 = toPath3(fileName);
162122
+ const file = program2.getSourceFileByPath(path5);
162123
+ return file && file.resolvedPath === path5 ? file : void 0;
162124
162124
  }
162125
162125
  function getOrCreateSourceFileLike(fileName) {
162126
- const path4 = toPath3(fileName);
162127
- const fileFromCache = sourceFileLike.get(path4);
162126
+ const path5 = toPath3(fileName);
162127
+ const fileFromCache = sourceFileLike.get(path5);
162128
162128
  if (fileFromCache !== void 0) return fileFromCache ? fileFromCache : void 0;
162129
162129
  if (!host.readFile || host.fileExists && !host.fileExists(fileName)) {
162130
- sourceFileLike.set(path4, false);
162130
+ sourceFileLike.set(path5, false);
162131
162131
  return void 0;
162132
162132
  }
162133
162133
  const text4 = host.readFile(fileName);
162134
162134
  const file = text4 ? createSourceFileLike(text4) : false;
162135
- sourceFileLike.set(path4, file);
162135
+ sourceFileLike.set(path5, file);
162136
162136
  return file ? file : void 0;
162137
162137
  }
162138
162138
  function getSourceFileLike(fileName) {
@@ -170218,12 +170218,12 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
170218
170218
  directoryExists: (directoryName) => {
170219
170219
  return directoryProbablyExists(directoryName, host);
170220
170220
  },
170221
- getDirectories: (path4) => {
170222
- return host.getDirectories ? host.getDirectories(path4) : [];
170221
+ getDirectories: (path5) => {
170222
+ return host.getDirectories ? host.getDirectories(path5) : [];
170223
170223
  },
170224
- readDirectory: (path4, extensions, exclude, include, depth) => {
170224
+ readDirectory: (path5, extensions, exclude, include, depth) => {
170225
170225
  Debug.checkDefined(host.readDirectory, "'LanguageServiceHost.readDirectory' must be implemented to correctly process 'projectReferences'");
170226
- return host.readDirectory(path4, extensions, exclude, include, depth);
170226
+ return host.readDirectory(path5, extensions, exclude, include, depth);
170227
170227
  },
170228
170228
  onReleaseOldSourceFile,
170229
170229
  onReleaseParsedCommandLine,
@@ -170286,11 +170286,11 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
170286
170286
  program2.getTypeChecker();
170287
170287
  return;
170288
170288
  function getParsedCommandLine(fileName) {
170289
- const path4 = toPath(fileName, currentDirectory, getCanonicalFileName);
170290
- const existing = parsedCommandLines == null ? void 0 : parsedCommandLines.get(path4);
170289
+ const path5 = toPath(fileName, currentDirectory, getCanonicalFileName);
170290
+ const existing = parsedCommandLines == null ? void 0 : parsedCommandLines.get(path5);
170291
170291
  if (existing !== void 0) return existing || void 0;
170292
170292
  const result = host.getParsedCommandLine ? host.getParsedCommandLine(fileName) : getParsedCommandLineOfConfigFileUsingSourceFile(fileName);
170293
- (parsedCommandLines || (parsedCommandLines = /* @__PURE__ */ new Map())).set(path4, result || false);
170293
+ (parsedCommandLines || (parsedCommandLines = /* @__PURE__ */ new Map())).set(path5, result || false);
170294
170294
  return result;
170295
170295
  }
170296
170296
  function getParsedCommandLineOfConfigFileUsingSourceFile(configFileName) {
@@ -170332,7 +170332,7 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
170332
170332
  function getOrCreateSourceFile(fileName, languageVersionOrOptions, onError, shouldCreateNewSourceFile) {
170333
170333
  return getOrCreateSourceFileByPath(fileName, toPath(fileName, currentDirectory, getCanonicalFileName), languageVersionOrOptions, onError, shouldCreateNewSourceFile);
170334
170334
  }
170335
- function getOrCreateSourceFileByPath(fileName, path4, languageVersionOrOptions, _onError, shouldCreateNewSourceFile) {
170335
+ function getOrCreateSourceFileByPath(fileName, path5, languageVersionOrOptions, _onError, shouldCreateNewSourceFile) {
170336
170336
  Debug.assert(compilerHost, "getOrCreateSourceFileByPath called after typical CompilerHost lifetime, check the callstack something with a reference to an old host.");
170337
170337
  const scriptSnapshot = host.getScriptSnapshot(fileName);
170338
170338
  if (!scriptSnapshot) {
@@ -170341,17 +170341,17 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
170341
170341
  const scriptKind = getScriptKind(fileName, host);
170342
170342
  const scriptVersion = host.getScriptVersion(fileName);
170343
170343
  if (!shouldCreateNewSourceFile) {
170344
- const oldSourceFile = program2 && program2.getSourceFileByPath(path4);
170344
+ const oldSourceFile = program2 && program2.getSourceFileByPath(path5);
170345
170345
  if (oldSourceFile) {
170346
170346
  if (scriptKind === oldSourceFile.scriptKind || releasedScriptKinds.has(oldSourceFile.resolvedPath)) {
170347
- return documentRegistry.updateDocumentWithKey(fileName, path4, host, documentRegistryBucketKey, scriptSnapshot, scriptVersion, scriptKind, languageVersionOrOptions);
170347
+ return documentRegistry.updateDocumentWithKey(fileName, path5, host, documentRegistryBucketKey, scriptSnapshot, scriptVersion, scriptKind, languageVersionOrOptions);
170348
170348
  } else {
170349
170349
  documentRegistry.releaseDocumentWithKey(oldSourceFile.resolvedPath, documentRegistry.getKeyForCompilationSettings(program2.getCompilerOptions()), oldSourceFile.scriptKind, oldSourceFile.impliedNodeFormat);
170350
170350
  releasedScriptKinds.add(oldSourceFile.resolvedPath);
170351
170351
  }
170352
170352
  }
170353
170353
  }
170354
- return documentRegistry.acquireDocumentWithKey(fileName, path4, host, documentRegistryBucketKey, scriptSnapshot, scriptVersion, scriptKind, languageVersionOrOptions);
170354
+ return documentRegistry.acquireDocumentWithKey(fileName, path5, host, documentRegistryBucketKey, scriptSnapshot, scriptVersion, scriptKind, languageVersionOrOptions);
170355
170355
  }
170356
170356
  }
170357
170357
  function getProgram() {
@@ -170957,7 +170957,7 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
170957
170957
  return isArray(action) ? Promise.all(action.map((a) => applySingleCodeActionCommand(a))) : applySingleCodeActionCommand(action);
170958
170958
  }
170959
170959
  function applySingleCodeActionCommand(action) {
170960
- const getPath2 = (path4) => toPath(path4, currentDirectory, getCanonicalFileName);
170960
+ const getPath2 = (path5) => toPath(path5, currentDirectory, getCanonicalFileName);
170961
170961
  Debug.assertEqual(action.type, "install package");
170962
170962
  return host.installPackage ? host.installPackage({ fileName: getPath2(action.file), packageName: action.packageName }) : Promise.reject("Host does not implement `installPackage`");
170963
170963
  }
@@ -171301,8 +171301,8 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
171301
171301
  function isLetterOrDigit(char) {
171302
171302
  return char >= 97 && char <= 122 || char >= 65 && char <= 90 || char >= 48 && char <= 57;
171303
171303
  }
171304
- function isNodeModulesFile(path4) {
171305
- return path4.includes("/node_modules/");
171304
+ function isNodeModulesFile(path5) {
171305
+ return path5.includes("/node_modules/");
171306
171306
  }
171307
171307
  }
171308
171308
  function getRenameInfo2(fileName, position, preferences) {
@@ -184936,11 +184936,11 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
184936
184936
  }
184937
184937
  });
184938
184938
  }
184939
- function generateJSDocParamTagsForDestructuring(path4, pattern, initializer, dotDotDotToken, isJs, isSnippet, checker, options, preferences) {
184939
+ function generateJSDocParamTagsForDestructuring(path5, pattern, initializer, dotDotDotToken, isJs, isSnippet, checker, options, preferences) {
184940
184940
  if (!isJs) {
184941
184941
  return [
184942
184942
  getJSDocParamAnnotation(
184943
- path4,
184943
+ path5,
184944
184944
  initializer,
184945
184945
  dotDotDotToken,
184946
184946
  isJs,
@@ -184954,7 +184954,7 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
184954
184954
  )
184955
184955
  ];
184956
184956
  }
184957
- return patternWorker(path4, pattern, initializer, dotDotDotToken, { tabstop: 1 });
184957
+ return patternWorker(path5, pattern, initializer, dotDotDotToken, { tabstop: 1 });
184958
184958
  function patternWorker(path22, pattern2, initializer2, dotDotDotToken2, counter) {
184959
184959
  if (isObjectBindingPattern(pattern2) && !dotDotDotToken2) {
184960
184960
  const oldTabstop = counter.tabstop;
@@ -189577,21 +189577,21 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
189577
189577
  function getFragmentDirectory(fragment) {
189578
189578
  return containsSlash(fragment) ? hasTrailingDirectorySeparator(fragment) ? fragment : getDirectoryPath(fragment) : void 0;
189579
189579
  }
189580
- function getCompletionsForPathMapping(path4, patterns, fragment, packageDirectory, extensionOptions, isExports, isImports, program2, host, moduleSpecifierResolutionHost) {
189581
- const parsedPath = tryParsePattern(path4);
189580
+ function getCompletionsForPathMapping(path5, patterns, fragment, packageDirectory, extensionOptions, isExports, isImports, program2, host, moduleSpecifierResolutionHost) {
189581
+ const parsedPath = tryParsePattern(path5);
189582
189582
  if (!parsedPath) {
189583
189583
  return emptyArray;
189584
189584
  }
189585
189585
  if (typeof parsedPath === "string") {
189586
189586
  return justPathMappingName(
189587
- path4,
189587
+ path5,
189588
189588
  "script"
189589
189589
  /* scriptElement */
189590
189590
  );
189591
189591
  }
189592
189592
  const remainingFragment = tryRemovePrefix(fragment, parsedPath.prefix);
189593
189593
  if (remainingFragment === void 0) {
189594
- const starIsFullPathComponent = endsWith(path4, "/*");
189594
+ const starIsFullPathComponent = endsWith(path5, "/*");
189595
189595
  return starIsFullPathComponent ? justPathMappingName(
189596
189596
  parsedPath.prefix,
189597
189597
  "directory"
@@ -189677,9 +189677,9 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
189677
189677
  function getDirectoryMatches(directoryName) {
189678
189678
  return mapDefined(tryGetDirectories(host, directoryName), (dir) => dir === "node_modules" ? void 0 : directoryResult(dir));
189679
189679
  }
189680
- function trimPrefixAndSuffix(path4, prefix) {
189680
+ function trimPrefixAndSuffix(path5, prefix) {
189681
189681
  return firstDefined(matchingSuffixes, (suffix) => {
189682
- const inner = withoutStartAndEnd(normalizePath(path4), prefix, suffix);
189682
+ const inner = withoutStartAndEnd(normalizePath(path5), prefix, suffix);
189683
189683
  return inner === void 0 ? void 0 : removeLeadingDirectorySeparator(inner);
189684
189684
  });
189685
189685
  }
@@ -189687,8 +189687,8 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
189687
189687
  function withoutStartAndEnd(s, start, end) {
189688
189688
  return startsWith(s, start) && endsWith(s, end) ? s.slice(start.length, s.length - end.length) : void 0;
189689
189689
  }
189690
- function removeLeadingDirectorySeparator(path4) {
189691
- return path4[0] === directorySeparator ? path4.slice(1) : path4;
189690
+ function removeLeadingDirectorySeparator(path5) {
189691
+ return path5[0] === directorySeparator ? path5.slice(1) : path5;
189692
189692
  }
189693
189693
  function getAmbientModuleCompletions(fragment, fragmentDirectory, checker) {
189694
189694
  const ambientModules = checker.getAmbientModules().map((sym) => stripQuotes(sym.name));
@@ -189803,10 +189803,10 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
189803
189803
  /* ESNext */
189804
189804
  ) ? void 0 : createTextSpan(textStart + offset, length2);
189805
189805
  }
189806
- function isPathRelativeToScript(path4) {
189807
- if (path4 && path4.length >= 2 && path4.charCodeAt(0) === 46) {
189808
- const slashIndex = path4.length >= 3 && path4.charCodeAt(1) === 46 ? 2 : 1;
189809
- const slashCharCode = path4.charCodeAt(slashIndex);
189806
+ function isPathRelativeToScript(path5) {
189807
+ if (path5 && path5.length >= 2 && path5.charCodeAt(0) === 46) {
189808
+ const slashIndex = path5.length >= 3 && path5.charCodeAt(1) === 46 ? 2 : 1;
189809
+ const slashCharCode = path5.charCodeAt(slashIndex);
189810
189810
  return slashCharCode === 47 || slashCharCode === 92;
189811
189811
  }
189812
189812
  return false;
@@ -205777,17 +205777,17 @@ ${options.prefix}` : "\n" : options.prefix
205777
205777
  function createNormalizedPathMap() {
205778
205778
  const map2 = /* @__PURE__ */ new Map();
205779
205779
  return {
205780
- get(path4) {
205781
- return map2.get(path4);
205780
+ get(path5) {
205781
+ return map2.get(path5);
205782
205782
  },
205783
- set(path4, value) {
205784
- map2.set(path4, value);
205783
+ set(path5, value) {
205784
+ map2.set(path5, value);
205785
205785
  },
205786
- contains(path4) {
205787
- return map2.has(path4);
205786
+ contains(path5) {
205787
+ return map2.has(path5);
205788
205788
  },
205789
- remove(path4) {
205790
- map2.delete(path4);
205789
+ remove(path5) {
205790
+ map2.delete(path5);
205791
205791
  }
205792
205792
  };
205793
205793
  }
@@ -206300,12 +206300,12 @@ ${options.prefix}` : "\n" : options.prefix
206300
206300
  return fileName[0] === "^" || (fileName.includes("walkThroughSnippet:/") || fileName.includes("untitled:/")) && getBaseFileName(fileName)[0] === "^" || fileName.includes(":^") && !fileName.includes(directorySeparator);
206301
206301
  }
206302
206302
  var ScriptInfo = class {
206303
- constructor(host, fileName, scriptKind, hasMixedContent, path4, initialVersion) {
206303
+ constructor(host, fileName, scriptKind, hasMixedContent, path5, initialVersion) {
206304
206304
  this.host = host;
206305
206305
  this.fileName = fileName;
206306
206306
  this.scriptKind = scriptKind;
206307
206307
  this.hasMixedContent = hasMixedContent;
206308
- this.path = path4;
206308
+ this.path = path5;
206309
206309
  this.containingProjects = [];
206310
206310
  this.isDynamic = isDynamicFileName(fileName);
206311
206311
  this.textStorage = new TextStorage(host, this, initialVersion);
@@ -206940,8 +206940,8 @@ ${options.prefix}` : "\n" : options.prefix
206940
206940
  useCaseSensitiveFileNames() {
206941
206941
  return this.projectService.host.useCaseSensitiveFileNames;
206942
206942
  }
206943
- readDirectory(path4, extensions, exclude, include, depth) {
206944
- return this.directoryStructureHost.readDirectory(path4, extensions, exclude, include, depth);
206943
+ readDirectory(path5, extensions, exclude, include, depth) {
206944
+ return this.directoryStructureHost.readDirectory(path5, extensions, exclude, include, depth);
206945
206945
  }
206946
206946
  readFile(fileName) {
206947
206947
  return this.projectService.host.readFile(fileName);
@@ -206950,8 +206950,8 @@ ${options.prefix}` : "\n" : options.prefix
206950
206950
  return this.projectService.host.writeFile(fileName, content);
206951
206951
  }
206952
206952
  fileExists(file) {
206953
- const path4 = this.toPath(file);
206954
- return !!this.projectService.getScriptInfoForPath(path4) || !this.isWatchedMissingFile(path4) && this.directoryStructureHost.fileExists(file);
206953
+ const path5 = this.toPath(file);
206954
+ return !!this.projectService.getScriptInfoForPath(path5) || !this.isWatchedMissingFile(path5) && this.directoryStructureHost.fileExists(file);
206955
206955
  }
206956
206956
  /** @internal */
206957
206957
  resolveModuleNameLiterals(moduleLiterals, containingFile, redirectedReference, options, containingSourceFile, reusedNames) {
@@ -206976,11 +206976,11 @@ ${options.prefix}` : "\n" : options.prefix
206976
206976
  resolveLibrary(libraryName, resolveFrom, options, libFileName) {
206977
206977
  return this.resolutionCache.resolveLibrary(libraryName, resolveFrom, options, libFileName);
206978
206978
  }
206979
- directoryExists(path4) {
206980
- return this.directoryStructureHost.directoryExists(path4);
206979
+ directoryExists(path5) {
206980
+ return this.directoryStructureHost.directoryExists(path5);
206981
206981
  }
206982
- getDirectories(path4) {
206983
- return this.directoryStructureHost.getDirectories(path4);
206982
+ getDirectories(path5) {
206983
+ return this.directoryStructureHost.getDirectories(path5);
206984
206984
  }
206985
206985
  /** @internal */
206986
206986
  getCachedDirectoryStructureHost() {
@@ -207243,16 +207243,16 @@ ${options.prefix}` : "\n" : options.prefix
207243
207243
  }
207244
207244
  }));
207245
207245
  }
207246
- getSourceFile(path4) {
207246
+ getSourceFile(path5) {
207247
207247
  if (!this.program) {
207248
207248
  return void 0;
207249
207249
  }
207250
- return this.program.getSourceFileByPath(path4);
207250
+ return this.program.getSourceFileByPath(path5);
207251
207251
  }
207252
207252
  /** @internal */
207253
- getSourceFileOrConfigFile(path4) {
207253
+ getSourceFileOrConfigFile(path5) {
207254
207254
  const options = this.program.getCompilerOptions();
207255
- return path4 === options.configFilePath ? options.configFile : this.getSourceFile(path4);
207255
+ return path5 === options.configFilePath ? options.configFile : this.getSourceFile(path5);
207256
207256
  }
207257
207257
  close() {
207258
207258
  var _a;
@@ -207429,8 +207429,8 @@ ${options.prefix}` : "\n" : options.prefix
207429
207429
  }
207430
207430
  // add a root file that doesnt exist on host
207431
207431
  addMissingFileRoot(fileName) {
207432
- const path4 = this.projectService.toPath(fileName);
207433
- this.rootFilesMap.set(path4, { fileName });
207432
+ const path5 = this.projectService.toPath(fileName);
207433
+ this.rootFilesMap.set(path5, { fileName });
207434
207434
  this.markAsDirty();
207435
207435
  }
207436
207436
  removeFile(info, fileExists, detachFromProject) {
@@ -207596,22 +207596,22 @@ ${options.prefix}` : "\n" : options.prefix
207596
207596
  const toRemove = new Map(this.typingWatchers);
207597
207597
  if (!this.typingWatchers) this.typingWatchers = /* @__PURE__ */ new Map();
207598
207598
  this.typingWatchers.isInvoked = false;
207599
- const createProjectWatcher = (path4, typingsWatcherType) => {
207600
- const canonicalPath = this.toPath(path4);
207599
+ const createProjectWatcher = (path5, typingsWatcherType) => {
207600
+ const canonicalPath = this.toPath(path5);
207601
207601
  toRemove.delete(canonicalPath);
207602
207602
  if (!this.typingWatchers.has(canonicalPath)) {
207603
207603
  const watchType = typingsWatcherType === "FileWatcher" ? WatchType.TypingInstallerLocationFile : WatchType.TypingInstallerLocationDirectory;
207604
207604
  this.typingWatchers.set(
207605
207605
  canonicalPath,
207606
207606
  canWatchDirectoryOrFilePath(canonicalPath) ? typingsWatcherType === "FileWatcher" ? this.projectService.watchFactory.watchFile(
207607
- path4,
207607
+ path5,
207608
207608
  () => !this.typingWatchers.isInvoked ? this.onTypingInstallerWatchInvoke() : this.writeLog(`TypingWatchers already invoked`),
207609
207609
  2e3,
207610
207610
  this.projectService.getWatchOptions(this),
207611
207611
  watchType,
207612
207612
  this
207613
207613
  ) : this.projectService.watchFactory.watchDirectory(
207614
- path4,
207614
+ path5,
207615
207615
  (f) => {
207616
207616
  if (this.typingWatchers.isInvoked) return this.writeLog(`TypingWatchers already invoked`);
207617
207617
  if (!fileExtensionIs(
@@ -207626,7 +207626,7 @@ ${options.prefix}` : "\n" : options.prefix
207626
207626
  this.projectService.getWatchOptions(this),
207627
207627
  watchType,
207628
207628
  this
207629
- ) : (this.writeLog(`Skipping watcher creation at ${path4}:: ${getDetailWatchInfo(watchType, this)}`), noopFileWatcher)
207629
+ ) : (this.writeLog(`Skipping watcher creation at ${path5}:: ${getDetailWatchInfo(watchType, this)}`), noopFileWatcher)
207630
207630
  );
207631
207631
  }
207632
207632
  };
@@ -207671,9 +207671,9 @@ ${options.prefix}` : "\n" : options.prefix
207671
207671
  /* DirectoryWatcher */
207672
207672
  );
207673
207673
  }
207674
- toRemove.forEach((watch, path4) => {
207674
+ toRemove.forEach((watch, path5) => {
207675
207675
  watch.close();
207676
- this.typingWatchers.delete(path4);
207676
+ this.typingWatchers.delete(path5);
207677
207677
  });
207678
207678
  }
207679
207679
  /** @internal */
@@ -207707,9 +207707,9 @@ ${options.prefix}` : "\n" : options.prefix
207707
207707
  let hasNewProgram = false;
207708
207708
  if (this.program && (!oldProgram || this.program !== oldProgram && this.program.structureIsReused !== 2)) {
207709
207709
  hasNewProgram = true;
207710
- this.rootFilesMap.forEach((value, path4) => {
207710
+ this.rootFilesMap.forEach((value, path5) => {
207711
207711
  var _a2;
207712
- const file = this.program.getSourceFileByPath(path4);
207712
+ const file = this.program.getSourceFileByPath(path5);
207713
207713
  const info = value.info;
207714
207714
  if (!file || ((_a2 = value.info) == null ? void 0 : _a2.path) === file.resolvedPath) return;
207715
207715
  value.info = this.projectService.getScriptInfo(file.fileName);
@@ -207865,8 +207865,8 @@ ${options.prefix}` : "\n" : options.prefix
207865
207865
  );
207866
207866
  return fileWatcher;
207867
207867
  }
207868
- isWatchedMissingFile(path4) {
207869
- return !!this.missingFilesMap && this.missingFilesMap.has(path4);
207868
+ isWatchedMissingFile(path5) {
207869
+ return !!this.missingFilesMap && this.missingFilesMap.has(path5);
207870
207870
  }
207871
207871
  /** @internal */
207872
207872
  addGeneratedFileWatch(generatedFile, sourceFile) {
@@ -207875,17 +207875,17 @@ ${options.prefix}` : "\n" : options.prefix
207875
207875
  this.generatedFilesMap = this.createGeneratedFileWatcher(generatedFile);
207876
207876
  }
207877
207877
  } else {
207878
- const path4 = this.toPath(sourceFile);
207878
+ const path5 = this.toPath(sourceFile);
207879
207879
  if (this.generatedFilesMap) {
207880
207880
  if (isGeneratedFileWatcher(this.generatedFilesMap)) {
207881
207881
  Debug.fail(`${this.projectName} Expected to not have --out watcher for generated file with options: ${JSON.stringify(this.compilerOptions)}`);
207882
207882
  return;
207883
207883
  }
207884
- if (this.generatedFilesMap.has(path4)) return;
207884
+ if (this.generatedFilesMap.has(path5)) return;
207885
207885
  } else {
207886
207886
  this.generatedFilesMap = /* @__PURE__ */ new Map();
207887
207887
  }
207888
- this.generatedFilesMap.set(path4, this.createGeneratedFileWatcher(generatedFile));
207888
+ this.generatedFilesMap.set(path5, this.createGeneratedFileWatcher(generatedFile));
207889
207889
  }
207890
207890
  }
207891
207891
  createGeneratedFileWatcher(generatedFile) {
@@ -208285,7 +208285,7 @@ ${options.prefix}` : "\n" : options.prefix
208285
208285
  isDefaultProjectForOpenFiles() {
208286
208286
  return !!forEachEntry(
208287
208287
  this.projectService.openFiles,
208288
- (_projectRootPath, path4) => this.projectService.tryGetDefaultProjectForFile(this.projectService.getScriptInfoForPath(path4)) === this
208288
+ (_projectRootPath, path5) => this.projectService.tryGetDefaultProjectForFile(this.projectService.getScriptInfoForPath(path5)) === this
208289
208289
  );
208290
208290
  }
208291
208291
  /** @internal */
@@ -209459,33 +209459,33 @@ ${options.prefix}` : "\n" : options.prefix
209459
209459
  getCurrentDirectory: () => service.host.getCurrentDirectory(),
209460
209460
  useCaseSensitiveFileNames: service.host.useCaseSensitiveFileNames
209461
209461
  };
209462
- function watchFile2(path4, callback) {
209462
+ function watchFile2(path5, callback) {
209463
209463
  return getOrCreateFileWatcher(
209464
209464
  watchedFiles,
209465
- path4,
209465
+ path5,
209466
209466
  callback,
209467
- (id) => ({ eventName: CreateFileWatcherEvent, data: { id, path: path4 } })
209467
+ (id) => ({ eventName: CreateFileWatcherEvent, data: { id, path: path5 } })
209468
209468
  );
209469
209469
  }
209470
- function watchDirectory(path4, callback, recursive) {
209470
+ function watchDirectory(path5, callback, recursive) {
209471
209471
  return getOrCreateFileWatcher(
209472
209472
  recursive ? watchedDirectoriesRecursive : watchedDirectories,
209473
- path4,
209473
+ path5,
209474
209474
  callback,
209475
209475
  (id) => ({
209476
209476
  eventName: CreateDirectoryWatcherEvent,
209477
209477
  data: {
209478
209478
  id,
209479
- path: path4,
209479
+ path: path5,
209480
209480
  recursive: !!recursive,
209481
209481
  // Special case node_modules as we watch it for changes to closed script infos as well
209482
- ignoreUpdate: !path4.endsWith("/node_modules") ? true : void 0
209482
+ ignoreUpdate: !path5.endsWith("/node_modules") ? true : void 0
209483
209483
  }
209484
209484
  })
209485
209485
  );
209486
209486
  }
209487
- function getOrCreateFileWatcher({ pathToId, idToCallbacks }, path4, callback, event) {
209488
- const key = service.toPath(path4);
209487
+ function getOrCreateFileWatcher({ pathToId, idToCallbacks }, path5, callback, event) {
209488
+ const key = service.toPath(path5);
209489
209489
  let id = pathToId.get(key);
209490
209490
  if (!id) pathToId.set(key, id = ids++);
209491
209491
  let callbacks = idToCallbacks.get(id);
@@ -209654,13 +209654,13 @@ ${options.prefix}` : "\n" : options.prefix
209654
209654
  return getNormalizedAbsolutePath(fileName, this.host.getCurrentDirectory());
209655
209655
  }
209656
209656
  /** @internal */
209657
- setDocument(key, path4, sourceFile) {
209658
- const info = Debug.checkDefined(this.getScriptInfoForPath(path4));
209657
+ setDocument(key, path5, sourceFile) {
209658
+ const info = Debug.checkDefined(this.getScriptInfoForPath(path5));
209659
209659
  info.cacheSourceFile = { key, sourceFile };
209660
209660
  }
209661
209661
  /** @internal */
209662
- getDocument(key, path4) {
209663
- const info = this.getScriptInfoForPath(path4);
209662
+ getDocument(key, path5) {
209663
+ const info = this.getScriptInfoForPath(path5);
209664
209664
  return info && info.cacheSourceFile && info.cacheSourceFile.key === key ? info.cacheSourceFile.sourceFile : void 0;
209665
209665
  }
209666
209666
  /** @internal */
@@ -209782,7 +209782,7 @@ ${options.prefix}` : "\n" : options.prefix
209782
209782
  const event = {
209783
209783
  eventName: ProjectsUpdatedInBackgroundEvent,
209784
209784
  data: {
209785
- openFiles: arrayFrom(this.openFiles.keys(), (path4) => this.getScriptInfoForPath(path4).fileName)
209785
+ openFiles: arrayFrom(this.openFiles.keys(), (path5) => this.getScriptInfoForPath(path5).fileName)
209786
209786
  }
209787
209787
  };
209788
209788
  this.eventHandler(event);
@@ -210004,11 +210004,11 @@ ${options.prefix}` : "\n" : options.prefix
210004
210004
  }
210005
210005
  delayUpdateSourceInfoProjects(sourceInfos) {
210006
210006
  if (sourceInfos) {
210007
- sourceInfos.forEach((_value, path4) => this.delayUpdateProjectsOfScriptInfoPath(path4));
210007
+ sourceInfos.forEach((_value, path5) => this.delayUpdateProjectsOfScriptInfoPath(path5));
210008
210008
  }
210009
210009
  }
210010
- delayUpdateProjectsOfScriptInfoPath(path4) {
210011
- const info = this.getScriptInfoForPath(path4);
210010
+ delayUpdateProjectsOfScriptInfoPath(path5) {
210011
+ const info = this.getScriptInfoForPath(path5);
210012
210012
  if (info) {
210013
210013
  this.delayUpdateProjectGraphs(
210014
210014
  info.containingProjects,
@@ -210102,8 +210102,8 @@ ${options.prefix}` : "\n" : options.prefix
210102
210102
  const project = this.getConfiguredProjectByCanonicalConfigFilePath(projectCanonicalPath);
210103
210103
  if (!project) return;
210104
210104
  if (configuredProjectForConfig !== project && this.getHostPreferences().includeCompletionsForModuleExports) {
210105
- const path4 = this.toPath(configFileName);
210106
- if (find((_a = project.getCurrentProgram()) == null ? void 0 : _a.getResolvedProjectReferences(), (ref) => (ref == null ? void 0 : ref.sourceFile.path) === path4)) {
210105
+ const path5 = this.toPath(configFileName);
210106
+ if (find((_a = project.getCurrentProgram()) == null ? void 0 : _a.getResolvedProjectReferences(), (ref) => (ref == null ? void 0 : ref.sourceFile.path) === path5)) {
210107
210107
  project.markAutoImportProviderAsDirty();
210108
210108
  }
210109
210109
  }
@@ -210158,10 +210158,10 @@ ${options.prefix}` : "\n" : options.prefix
210158
210158
  });
210159
210159
  return;
210160
210160
  }
210161
- const path4 = this.toPath(canonicalConfigFilePath);
210162
- project.resolutionCache.removeResolutionsFromProjectReferenceRedirects(path4);
210161
+ const path5 = this.toPath(canonicalConfigFilePath);
210162
+ project.resolutionCache.removeResolutionsFromProjectReferenceRedirects(path5);
210163
210163
  this.delayUpdateProjectGraph(project);
210164
- if (this.getHostPreferences().includeCompletionsForModuleExports && find((_c = project.getCurrentProgram()) == null ? void 0 : _c.getResolvedProjectReferences(), (ref) => (ref == null ? void 0 : ref.sourceFile.path) === path4)) {
210164
+ if (this.getHostPreferences().includeCompletionsForModuleExports && find((_c = project.getCurrentProgram()) == null ? void 0 : _c.getResolvedProjectReferences(), (ref) => (ref == null ? void 0 : ref.sourceFile.path) === path5)) {
210165
210165
  project.markAutoImportProviderAsDirty();
210166
210166
  }
210167
210167
  }
@@ -210186,20 +210186,20 @@ ${options.prefix}` : "\n" : options.prefix
210186
210186
  canonicalConfigFilePath,
210187
210187
  "Change in config file detected"
210188
210188
  );
210189
- this.openFiles.forEach((_projectRootPath, path4) => {
210189
+ this.openFiles.forEach((_projectRootPath, path5) => {
210190
210190
  var _a, _b;
210191
- const configFileForOpenFile = this.configFileForOpenFiles.get(path4);
210192
- if (!((_a = configFileExistenceInfo.openFilesImpactedByConfigFile) == null ? void 0 : _a.has(path4))) return;
210193
- this.configFileForOpenFiles.delete(path4);
210194
- const info = this.getScriptInfoForPath(path4);
210191
+ const configFileForOpenFile = this.configFileForOpenFiles.get(path5);
210192
+ if (!((_a = configFileExistenceInfo.openFilesImpactedByConfigFile) == null ? void 0 : _a.has(path5))) return;
210193
+ this.configFileForOpenFiles.delete(path5);
210194
+ const info = this.getScriptInfoForPath(path5);
210195
210195
  const newConfigFileNameForInfo = this.getConfigFileNameForFile(
210196
210196
  info,
210197
210197
  /*findFromCacheOnly*/
210198
210198
  false
210199
210199
  );
210200
210200
  if (!newConfigFileNameForInfo) return;
210201
- if (!((_b = this.pendingOpenFileProjectUpdates) == null ? void 0 : _b.has(path4))) {
210202
- (this.pendingOpenFileProjectUpdates ?? (this.pendingOpenFileProjectUpdates = /* @__PURE__ */ new Map())).set(path4, configFileForOpenFile);
210201
+ if (!((_b = this.pendingOpenFileProjectUpdates) == null ? void 0 : _b.has(path5))) {
210202
+ (this.pendingOpenFileProjectUpdates ?? (this.pendingOpenFileProjectUpdates = /* @__PURE__ */ new Map())).set(path5, configFileForOpenFile);
210203
210203
  }
210204
210204
  });
210205
210205
  this.delayEnsureProjectForOpenFiles();
@@ -210294,8 +210294,8 @@ ${options.prefix}` : "\n" : options.prefix
210294
210294
  return project;
210295
210295
  }
210296
210296
  assignOrphanScriptInfosToInferredProject() {
210297
- this.openFiles.forEach((projectRootPath, path4) => {
210298
- const info = this.getScriptInfoForPath(path4);
210297
+ this.openFiles.forEach((projectRootPath, path5) => {
210298
+ const info = this.getScriptInfoForPath(path5);
210299
210299
  if (info.isOrphan()) {
210300
210300
  this.assignOrphanScriptInfoToInferredProject(info, projectRootPath);
210301
210301
  }
@@ -210607,8 +210607,8 @@ ${options.prefix}` : "\n" : options.prefix
210607
210607
  this.configuredProjects.forEach(printProjectWithoutFileNames);
210608
210608
  this.inferredProjects.forEach(printProjectWithoutFileNames);
210609
210609
  this.logger.info("Open files: ");
210610
- this.openFiles.forEach((projectRootPath, path4) => {
210611
- const info = this.getScriptInfoForPath(path4);
210610
+ this.openFiles.forEach((projectRootPath, path5) => {
210611
+ const info = this.getScriptInfoForPath(path5);
210612
210612
  this.logger.info(` FileName: ${info.fileName} ProjectRootPath: ${projectRootPath}`);
210613
210613
  this.logger.info(` Projects: ${info.containingProjects.map((p9) => p9.getProjectName())}`);
210614
210614
  });
@@ -210934,12 +210934,12 @@ ${options.prefix}` : "\n" : options.prefix
210934
210934
  const newRootFile = propertyReader.getFileName(f);
210935
210935
  const fileName = toNormalizedPath(newRootFile);
210936
210936
  const isDynamic = isDynamicFileName(fileName);
210937
- let path4;
210937
+ let path5;
210938
210938
  if (!isDynamic && !project.fileExists(newRootFile)) {
210939
- path4 = normalizedPathToPath(fileName, this.currentDirectory, this.toCanonicalFileName);
210940
- const existingValue = projectRootFilesMap.get(path4);
210939
+ path5 = normalizedPathToPath(fileName, this.currentDirectory, this.toCanonicalFileName);
210940
+ const existingValue = projectRootFilesMap.get(path5);
210941
210941
  if (existingValue) {
210942
- if (((_a = existingValue.info) == null ? void 0 : _a.path) === path4) {
210942
+ if (((_a = existingValue.info) == null ? void 0 : _a.path) === path5) {
210943
210943
  project.removeFile(
210944
210944
  existingValue.info,
210945
210945
  /*fileExists*/
@@ -210951,7 +210951,7 @@ ${options.prefix}` : "\n" : options.prefix
210951
210951
  }
210952
210952
  existingValue.fileName = fileName;
210953
210953
  } else {
210954
- projectRootFilesMap.set(path4, { fileName });
210954
+ projectRootFilesMap.set(path5, { fileName });
210955
210955
  }
210956
210956
  } else {
210957
210957
  const scriptKind = propertyReader.getScriptKind(f, this.hostConfiguration.extraFileExtensions);
@@ -210965,8 +210965,8 @@ ${options.prefix}` : "\n" : options.prefix
210965
210965
  /*deferredDeleteOk*/
210966
210966
  false
210967
210967
  ));
210968
- path4 = scriptInfo.path;
210969
- const existingValue = projectRootFilesMap.get(path4);
210968
+ path5 = scriptInfo.path;
210969
+ const existingValue = projectRootFilesMap.get(path5);
210970
210970
  if (!existingValue || existingValue.info !== scriptInfo) {
210971
210971
  project.addRoot(scriptInfo, fileName);
210972
210972
  if (scriptInfo.isScriptOpen()) {
@@ -210976,11 +210976,11 @@ ${options.prefix}` : "\n" : options.prefix
210976
210976
  existingValue.fileName = fileName;
210977
210977
  }
210978
210978
  }
210979
- newRootScriptInfoMap.set(path4, true);
210979
+ newRootScriptInfoMap.set(path5, true);
210980
210980
  }
210981
210981
  if (projectRootFilesMap.size > newRootScriptInfoMap.size) {
210982
- projectRootFilesMap.forEach((value, path4) => {
210983
- if (!newRootScriptInfoMap.has(path4)) {
210982
+ projectRootFilesMap.forEach((value, path5) => {
210983
+ if (!newRootScriptInfoMap.has(path5)) {
210984
210984
  if (value.info) {
210985
210985
  project.removeFile(
210986
210986
  value.info,
@@ -210989,7 +210989,7 @@ ${options.prefix}` : "\n" : options.prefix
210989
210989
  true
210990
210990
  );
210991
210991
  } else {
210992
- projectRootFilesMap.delete(path4);
210992
+ projectRootFilesMap.delete(path5);
210993
210993
  }
210994
210994
  }
210995
210995
  });
@@ -211226,8 +211226,8 @@ ${options.prefix}` : "\n" : options.prefix
211226
211226
  }
211227
211227
  /** @internal */
211228
211228
  getScriptInfoOrConfig(uncheckedFileName) {
211229
- const path4 = toNormalizedPath(uncheckedFileName);
211230
- const info = this.getScriptInfoForNormalizedPath(path4);
211229
+ const path5 = toNormalizedPath(uncheckedFileName);
211230
+ const info = this.getScriptInfoForNormalizedPath(path5);
211231
211231
  if (info) return info;
211232
211232
  const configProject = this.configuredProjects.get(this.toPath(uncheckedFileName));
211233
211233
  return configProject && configProject.getCompilerOptions().configFile;
@@ -211239,7 +211239,7 @@ ${options.prefix}` : "\n" : options.prefix
211239
211239
  this.filenameToScriptInfo.entries(),
211240
211240
  (entry) => entry[1].deferredDelete ? void 0 : entry
211241
211241
  ),
211242
- ([path4, scriptInfo]) => ({ path: path4, fileName: scriptInfo.fileName })
211242
+ ([path5, scriptInfo]) => ({ path: path5, fileName: scriptInfo.fileName })
211243
211243
  );
211244
211244
  this.logger.msg(
211245
211245
  `Could not find file ${JSON.stringify(fileName)}.
@@ -211271,7 +211271,7 @@ All files are: ${JSON.stringify(names)}`,
211271
211271
  if (!projects2) {
211272
211272
  projects2 = createMultiMap();
211273
211273
  projects2.add(toAddInfo.path, project);
211274
- } else if (!forEachEntry(projects2, (projs, path4) => path4 === toAddInfo.path ? false : contains(projs, project))) {
211274
+ } else if (!forEachEntry(projects2, (projs, path5) => path5 === toAddInfo.path ? false : contains(projs, project))) {
211275
211275
  projects2.add(toAddInfo.path, project);
211276
211276
  }
211277
211277
  }
@@ -211433,8 +211433,8 @@ All files are: ${JSON.stringify(names)}`,
211433
211433
  }
211434
211434
  getOrCreateScriptInfoWorker(fileName, currentDirectory, openedByClient, fileContent, scriptKind, hasMixedContent, hostToQueryFileExistsOn, deferredDeleteOk) {
211435
211435
  Debug.assert(fileContent === void 0 || openedByClient, "ScriptInfo needs to be opened by client to be able to set its user defined content");
211436
- const path4 = normalizedPathToPath(fileName, currentDirectory, this.toCanonicalFileName);
211437
- let info = this.filenameToScriptInfo.get(path4);
211436
+ const path5 = normalizedPathToPath(fileName, currentDirectory, this.toCanonicalFileName);
211437
+ let info = this.filenameToScriptInfo.get(path5);
211438
211438
  if (!info) {
211439
211439
  const isDynamic = isDynamicFileName(fileName);
211440
211440
  Debug.assert(isRootedDiskPath(fileName) || isDynamic || openedByClient, "", () => `${JSON.stringify({ fileName, currentDirectory, hostCurrentDirectory: this.currentDirectory, openKeys: arrayFrom(this.openFilesWithNonRootedDiskPath.keys()) })}
@@ -211446,7 +211446,7 @@ Dynamic files must always be opened with service's current directory or service
211446
211446
  if (!openedByClient && !isDynamic && !(hostToQueryFileExistsOn || this.host).fileExists(fileName)) {
211447
211447
  return;
211448
211448
  }
211449
- info = new ScriptInfo(this.host, fileName, scriptKind, hasMixedContent, path4, this.filenameToScriptInfoVersion.get(path4));
211449
+ info = new ScriptInfo(this.host, fileName, scriptKind, hasMixedContent, path5, this.filenameToScriptInfoVersion.get(path5));
211450
211450
  this.filenameToScriptInfo.set(info.path, info);
211451
211451
  this.filenameToScriptInfoVersion.delete(info.path);
211452
211452
  if (!openedByClient) {
@@ -211593,9 +211593,9 @@ Dynamic files must always be opened with service's current directory or service
211593
211593
  getSourceFileLike(fileName, projectNameOrProject, declarationInfo) {
211594
211594
  const project = projectNameOrProject.projectName ? projectNameOrProject : this.findProject(projectNameOrProject);
211595
211595
  if (project) {
211596
- const path4 = project.toPath(fileName);
211597
- const sourceFile = project.getSourceFile(path4);
211598
- if (sourceFile && sourceFile.resolvedPath === path4) return sourceFile;
211596
+ const path5 = project.toPath(fileName);
211597
+ const sourceFile = project.getSourceFile(path5);
211598
+ if (sourceFile && sourceFile.resolvedPath === path5) return sourceFile;
211599
211599
  }
211600
211600
  const info = this.getOrCreateScriptInfoNotOpenedByClient(
211601
211601
  fileName,
@@ -211761,8 +211761,8 @@ Dynamic files must always be opened with service's current directory or service
211761
211761
  }
211762
211762
  });
211763
211763
  });
211764
- this.openFiles.forEach((_projectRootPath, path4) => {
211765
- const info = this.getScriptInfoForPath(path4);
211764
+ this.openFiles.forEach((_projectRootPath, path5) => {
211765
+ const info = this.getScriptInfoForPath(path5);
211766
211766
  if (find(info.containingProjects, isExternalProject)) return;
211767
211767
  this.tryFindDefaultConfiguredProjectAndLoadAncestorsForOpenScriptInfo(
211768
211768
  info,
@@ -211815,14 +211815,14 @@ Dynamic files must always be opened with service's current directory or service
211815
211815
  const pendingOpenFileProjectUpdates = this.pendingOpenFileProjectUpdates;
211816
211816
  this.pendingOpenFileProjectUpdates = void 0;
211817
211817
  pendingOpenFileProjectUpdates == null ? void 0 : pendingOpenFileProjectUpdates.forEach(
211818
- (_config, path4) => this.tryFindDefaultConfiguredProjectAndLoadAncestorsForOpenScriptInfo(
211819
- this.getScriptInfoForPath(path4),
211818
+ (_config, path5) => this.tryFindDefaultConfiguredProjectAndLoadAncestorsForOpenScriptInfo(
211819
+ this.getScriptInfoForPath(path5),
211820
211820
  5
211821
211821
  /* Create */
211822
211822
  )
211823
211823
  );
211824
- this.openFiles.forEach((projectRootPath, path4) => {
211825
- const info = this.getScriptInfoForPath(path4);
211824
+ this.openFiles.forEach((projectRootPath, path5) => {
211825
+ const info = this.getScriptInfoForPath(path5);
211826
211826
  if (info.isOrphan()) {
211827
211827
  this.assignOrphanScriptInfoToInferredProject(info, projectRootPath);
211828
211828
  } else {
@@ -212333,9 +212333,9 @@ Dynamic files must always be opened with service's current directory or service
212333
212333
  }
212334
212334
  });
212335
212335
  if (!toRemoveConfiguredProjects.size) return toRemoveConfiguredProjects;
212336
- forEachEntry(this.openFiles, (_projectRootPath, path4) => {
212337
- if (openFilesWithRetainedConfiguredProject == null ? void 0 : openFilesWithRetainedConfiguredProject.has(path4)) return;
212338
- const info = this.getScriptInfoForPath(path4);
212336
+ forEachEntry(this.openFiles, (_projectRootPath, path5) => {
212337
+ if (openFilesWithRetainedConfiguredProject == null ? void 0 : openFilesWithRetainedConfiguredProject.has(path5)) return;
212338
+ const info = this.getScriptInfoForPath(path5);
212339
212339
  if (find(info.containingProjects, isExternalProject)) return;
212340
212340
  const result = this.tryFindDefaultConfiguredProjectAndLoadAncestorsForOpenScriptInfo(
212341
212341
  info,
@@ -212384,8 +212384,8 @@ Dynamic files must always be opened with service's current directory or service
212384
212384
  sourceInfos = info.sourceMapFilePath.sourceInfos;
212385
212385
  }
212386
212386
  if (!sourceInfos) return;
212387
- if (!forEachKey(sourceInfos, (path4) => {
212388
- const info2 = this.getScriptInfoForPath(path4);
212387
+ if (!forEachKey(sourceInfos, (path5) => {
212388
+ const info2 = this.getScriptInfoForPath(path5);
212389
212389
  return !!info2 && (info2.isScriptOpen() || !info2.isOrphan());
212390
212390
  })) {
212391
212391
  return;
@@ -212409,7 +212409,7 @@ Dynamic files must always be opened with service's current directory or service
212409
212409
  sourceInfos = info.sourceMapFilePath.sourceInfos;
212410
212410
  }
212411
212411
  if (sourceInfos) {
212412
- sourceInfos.forEach((_value, path4) => toRemoveScriptInfos.delete(path4));
212412
+ sourceInfos.forEach((_value, path5) => toRemoveScriptInfos.delete(path5));
212413
212413
  }
212414
212414
  }
212415
212415
  });
@@ -212892,9 +212892,9 @@ Dynamic files must always be opened with service's current directory or service
212892
212892
  }
212893
212893
  );
212894
212894
  }
212895
- watchPackageJsonFile(file, path4, project) {
212895
+ watchPackageJsonFile(file, path5, project) {
212896
212896
  Debug.assert(project !== void 0);
212897
- let result = (this.packageJsonFilesMap ?? (this.packageJsonFilesMap = /* @__PURE__ */ new Map())).get(path4);
212897
+ let result = (this.packageJsonFilesMap ?? (this.packageJsonFilesMap = /* @__PURE__ */ new Map())).get(path5);
212898
212898
  if (!result) {
212899
212899
  let watcher = this.watchFactory.watchFile(
212900
212900
  file,
@@ -212902,11 +212902,11 @@ Dynamic files must always be opened with service's current directory or service
212902
212902
  switch (eventKind) {
212903
212903
  case 0:
212904
212904
  case 1:
212905
- this.packageJsonCache.addOrUpdate(fileName, path4);
212905
+ this.packageJsonCache.addOrUpdate(fileName, path5);
212906
212906
  this.onPackageJsonChange(result);
212907
212907
  break;
212908
212908
  case 2:
212909
- this.packageJsonCache.delete(path4);
212909
+ this.packageJsonCache.delete(path5);
212910
212910
  this.onPackageJsonChange(result);
212911
212911
  result.projects.clear();
212912
212912
  result.close();
@@ -212923,11 +212923,11 @@ Dynamic files must always be opened with service's current directory or service
212923
212923
  if (result.projects.size || !watcher) return;
212924
212924
  watcher.close();
212925
212925
  watcher = void 0;
212926
- (_a = this.packageJsonFilesMap) == null ? void 0 : _a.delete(path4);
212927
- this.packageJsonCache.invalidate(path4);
212926
+ (_a = this.packageJsonFilesMap) == null ? void 0 : _a.delete(path5);
212927
+ this.packageJsonCache.invalidate(path5);
212928
212928
  }
212929
212929
  };
212930
- this.packageJsonFilesMap.set(path4, result);
212930
+ this.packageJsonFilesMap.set(path5, result);
212931
212931
  }
212932
212932
  result.projects.add(project);
212933
212933
  (project.packageJsonWatches ?? (project.packageJsonWatches = /* @__PURE__ */ new Set())).add(result);
@@ -213117,14 +213117,14 @@ Dynamic files must always be opened with service's current directory or service
213117
213117
  );
213118
213118
  }
213119
213119
  };
213120
- function addOrUpdate(fileName, path4) {
213120
+ function addOrUpdate(fileName, path5) {
213121
213121
  const packageJsonInfo = Debug.checkDefined(createPackageJsonInfo(fileName, host.host));
213122
- packageJsons.set(path4, packageJsonInfo);
213123
- directoriesWithoutPackageJson.delete(getDirectoryPath(path4));
213122
+ packageJsons.set(path5, packageJsonInfo);
213123
+ directoriesWithoutPackageJson.delete(getDirectoryPath(path5));
213124
213124
  }
213125
- function invalidate(path4) {
213126
- packageJsons.delete(path4);
213127
- directoriesWithoutPackageJson.delete(getDirectoryPath(path4));
213125
+ function invalidate(path5) {
213126
+ packageJsons.delete(path5);
213127
+ directoriesWithoutPackageJson.delete(getDirectoryPath(path5));
213128
213128
  }
213129
213129
  function directoryHasPackageJson(directory) {
213130
213130
  return packageJsons.has(combinePaths(directory, "package.json")) ? -1 : directoriesWithoutPackageJson.has(directory) ? 0 : 3;
@@ -213321,8 +213321,8 @@ ${json}${newLine}`;
213321
213321
  function combineProjectOutput(defaultValue, getValue, projects2, action) {
213322
213322
  const outputs = flatMapToMutable(isArray(projects2) ? projects2 : projects2.projects, (project) => action(project, defaultValue));
213323
213323
  if (!isArray(projects2) && projects2.symLinkedProjects) {
213324
- projects2.symLinkedProjects.forEach((projects22, path4) => {
213325
- const value = getValue(path4);
213324
+ projects2.symLinkedProjects.forEach((projects22, path5) => {
213325
+ const value = getValue(path5);
213326
213326
  outputs.push(...flatMap(projects22, (project) => action(project, value)));
213327
213327
  });
213328
213328
  }
@@ -213468,9 +213468,9 @@ ${json}${newLine}`;
213468
213468
  });
213469
213469
  return results.filter((o) => o.references.length !== 0);
213470
213470
  }
213471
- function forEachProjectInProjects(projects2, path4, cb) {
213471
+ function forEachProjectInProjects(projects2, path5, cb) {
213472
213472
  for (const project of isArray(projects2) ? projects2 : projects2.projects) {
213473
- cb(project, path4);
213473
+ cb(project, path5);
213474
213474
  }
213475
213475
  if (!isArray(projects2) && projects2.symLinkedProjects) {
213476
213476
  projects2.symLinkedProjects.forEach((symlinkedProjects, symlinkedPath) => {
@@ -213484,8 +213484,8 @@ ${json}${newLine}`;
213484
213484
  const resultsMap = /* @__PURE__ */ new Map();
213485
213485
  const queue = createQueue();
213486
213486
  queue.enqueue({ project: defaultProject, location: initialLocation });
213487
- forEachProjectInProjects(projects2, initialLocation.fileName, (project, path4) => {
213488
- const location = { fileName: path4, pos: initialLocation.pos };
213487
+ forEachProjectInProjects(projects2, initialLocation.fileName, (project, path5) => {
213488
+ const location = { fileName: path5, pos: initialLocation.pos };
213489
213489
  queue.enqueue({ project, location });
213490
213490
  });
213491
213491
  const projectService = defaultProject.projectService;
@@ -215327,8 +215327,8 @@ Project '${project.projectName}' (${ProjectKind[project.projectKind]}) ${counter
215327
215327
  nodeModulesPathParts.packageRootIndex
215328
215328
  );
215329
215329
  const packageName = getPackageNameFromTypesPackageName(unmangleScopedPackageName(packageNamePathPart));
215330
- const path4 = project.toPath(fileName);
215331
- if (entrypoints && some(entrypoints, (e) => project.toPath(e) === path4)) {
215330
+ const path5 = project.toPath(fileName);
215331
+ if (entrypoints && some(entrypoints, (e) => project.toPath(e) === path5)) {
215332
215332
  return (_b = auxiliaryProject.resolutionCache.resolveSingleModuleNameWithoutWatching(packageName, resolveFromFile).resolvedModule) == null ? void 0 : _b.resolvedFileName;
215333
215333
  } else {
215334
215334
  const pathToFileInPackage = fileName.substring(nodeModulesPathParts.packageRootIndex + 1);
@@ -216108,7 +216108,7 @@ Project '${project.projectName}' (${ProjectKind[project.projectKind]}) ${counter
216108
216108
  }
216109
216109
  return combineProjectOutput(
216110
216110
  info,
216111
- (path4) => this.projectService.getScriptInfoForPath(path4),
216111
+ (path5) => this.projectService.getScriptInfoForPath(path5),
216112
216112
  projects2,
216113
216113
  (project, info2) => {
216114
216114
  if (!project.compileOnSaveEnabled || !project.languageServiceEnabled || project.isOrphan()) {
@@ -216135,7 +216135,7 @@ Project '${project.projectName}' (${ProjectKind[project.projectKind]}) ${counter
216135
216135
  return args.richResponse ? { emitSkipped: true, diagnostics: [] } : false;
216136
216136
  }
216137
216137
  const scriptInfo = project.getScriptInfo(file);
216138
- const { emitSkipped, diagnostics } = project.emitFile(scriptInfo, (path4, data, writeByteOrderMark) => this.host.writeFile(path4, data, writeByteOrderMark));
216138
+ const { emitSkipped, diagnostics } = project.emitFile(scriptInfo, (path5, data, writeByteOrderMark) => this.host.writeFile(path5, data, writeByteOrderMark));
216139
216139
  return args.richResponse ? {
216140
216140
  emitSkipped,
216141
216141
  diagnostics: args.includeLinePosition ? this.convertToDiagnosticsWithLinePositionFromDiagnosticFile(diagnostics) : diagnostics.map((d) => formatDiagnosticToProtocol(
@@ -220419,8 +220419,8 @@ var require_uri_all = __commonJS({
220419
220419
  wsComponents.secure = void 0;
220420
220420
  }
220421
220421
  if (wsComponents.resourceName) {
220422
- var _wsComponents$resourc = wsComponents.resourceName.split("?"), _wsComponents$resourc2 = slicedToArray(_wsComponents$resourc, 2), path4 = _wsComponents$resourc2[0], query = _wsComponents$resourc2[1];
220423
- wsComponents.path = path4 && path4 !== "/" ? path4 : void 0;
220422
+ var _wsComponents$resourc = wsComponents.resourceName.split("?"), _wsComponents$resourc2 = slicedToArray(_wsComponents$resourc, 2), path5 = _wsComponents$resourc2[0], query = _wsComponents$resourc2[1];
220423
+ wsComponents.path = path5 && path5 !== "/" ? path5 : void 0;
220424
220424
  wsComponents.query = query;
220425
220425
  wsComponents.resourceName = void 0;
220426
220426
  }
@@ -220796,12 +220796,12 @@ var require_util2 = __commonJS({
220796
220796
  return "'" + escapeQuotes(str) + "'";
220797
220797
  }
220798
220798
  function getPathExpr(currentPath, expr, jsonPointers, isNumber) {
220799
- var path4 = jsonPointers ? "'/' + " + expr + (isNumber ? "" : ".replace(/~/g, '~0').replace(/\\//g, '~1')") : isNumber ? "'[' + " + expr + " + ']'" : "'[\\'' + " + expr + " + '\\']'";
220800
- return joinPaths(currentPath, path4);
220799
+ var path5 = jsonPointers ? "'/' + " + expr + (isNumber ? "" : ".replace(/~/g, '~0').replace(/\\//g, '~1')") : isNumber ? "'[' + " + expr + " + ']'" : "'[\\'' + " + expr + " + '\\']'";
220800
+ return joinPaths(currentPath, path5);
220801
220801
  }
220802
220802
  function getPath2(currentPath, prop, jsonPointers) {
220803
- var path4 = jsonPointers ? toQuotedString("/" + escapeJsonPointer(prop)) : toQuotedString(getProperty(prop));
220804
- return joinPaths(currentPath, path4);
220803
+ var path5 = jsonPointers ? toQuotedString("/" + escapeJsonPointer(prop)) : toQuotedString(getProperty(prop));
220804
+ return joinPaths(currentPath, path5);
220805
220805
  }
220806
220806
  var JSON_POINTER = /^\/(?:[^~]|~0|~1)*$/;
220807
220807
  var RELATIVE_JSON_POINTER = /^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;
@@ -230295,8 +230295,8 @@ var require_utils = __commonJS({
230295
230295
  }
230296
230296
  return ind;
230297
230297
  }
230298
- function removeDotSegments(path4) {
230299
- let input = path4;
230298
+ function removeDotSegments(path5) {
230299
+ let input = path5;
230300
230300
  const output = [];
230301
230301
  let nextSlash = -1;
230302
230302
  let len = 0;
@@ -230496,8 +230496,8 @@ var require_schemes = __commonJS({
230496
230496
  wsComponent.secure = void 0;
230497
230497
  }
230498
230498
  if (wsComponent.resourceName) {
230499
- const [path4, query] = wsComponent.resourceName.split("?");
230500
- wsComponent.path = path4 && path4 !== "/" ? path4 : void 0;
230499
+ const [path5, query] = wsComponent.resourceName.split("?");
230500
+ wsComponent.path = path5 && path5 !== "/" ? path5 : void 0;
230501
230501
  wsComponent.query = query;
230502
230502
  wsComponent.resourceName = void 0;
230503
230503
  }
@@ -234772,70 +234772,70 @@ __export(json_comparison_exports, {
234772
234772
  function compareProjectDefinitions(original, generated) {
234773
234773
  const differences = [];
234774
234774
  const warnings = [];
234775
- const comparePrimitive = (path4, a, b) => {
234775
+ const comparePrimitive = (path5, a, b) => {
234776
234776
  if (a === b) return true;
234777
234777
  if (typeof a !== typeof b) {
234778
- differences.push(`Type mismatch at ${path4}: ${typeof a} vs ${typeof b}`);
234778
+ differences.push(`Type mismatch at ${path5}: ${typeof a} vs ${typeof b}`);
234779
234779
  return false;
234780
234780
  }
234781
234781
  if (a !== b) {
234782
- differences.push(`Value mismatch at ${path4}: "${a}" vs "${b}"`);
234782
+ differences.push(`Value mismatch at ${path5}: "${a}" vs "${b}"`);
234783
234783
  return false;
234784
234784
  }
234785
234785
  return true;
234786
234786
  };
234787
- const compareArrays = (path4, a, b) => {
234787
+ const compareArrays = (path5, a, b) => {
234788
234788
  if (a.length !== b.length) {
234789
- differences.push(`Array length mismatch at ${path4}: ${a.length} vs ${b.length}`);
234789
+ differences.push(`Array length mismatch at ${path5}: ${a.length} vs ${b.length}`);
234790
234790
  return false;
234791
234791
  }
234792
234792
  let allMatch = true;
234793
234793
  for (let i = 0; i < a.length; i++) {
234794
- if (!compareValues(`${path4}[${i}]`, a[i], b[i])) {
234794
+ if (!compareValues(`${path5}[${i}]`, a[i], b[i])) {
234795
234795
  allMatch = false;
234796
234796
  }
234797
234797
  }
234798
234798
  return allMatch;
234799
234799
  };
234800
- const compareObjects = (path4, a, b) => {
234800
+ const compareObjects = (path5, a, b) => {
234801
234801
  const aKeys = Object.keys(a || {}).filter((k) => !["createdAt", "updatedAt"].includes(k));
234802
234802
  const bKeys = Object.keys(b || {}).filter((k) => !["createdAt", "updatedAt"].includes(k));
234803
234803
  const missingInB = aKeys.filter((k) => !bKeys.includes(k));
234804
234804
  const extraInB = bKeys.filter((k) => !aKeys.includes(k));
234805
234805
  if (missingInB.length > 0) {
234806
- differences.push(`Missing keys in generated at ${path4}: ${missingInB.join(", ")}`);
234806
+ differences.push(`Missing keys in generated at ${path5}: ${missingInB.join(", ")}`);
234807
234807
  }
234808
234808
  if (extraInB.length > 0) {
234809
- warnings.push(`Extra keys in generated at ${path4}: ${extraInB.join(", ")}`);
234809
+ warnings.push(`Extra keys in generated at ${path5}: ${extraInB.join(", ")}`);
234810
234810
  }
234811
234811
  let allMatch = true;
234812
234812
  for (const key of aKeys) {
234813
234813
  if (bKeys.includes(key)) {
234814
- if (!compareValues(`${path4}.${key}`, a[key], b[key])) {
234814
+ if (!compareValues(`${path5}.${key}`, a[key], b[key])) {
234815
234815
  allMatch = false;
234816
234816
  }
234817
234817
  }
234818
234818
  }
234819
234819
  return allMatch && missingInB.length === 0;
234820
234820
  };
234821
- const compareValues = (path4, a, b) => {
234821
+ const compareValues = (path5, a, b) => {
234822
234822
  if (a === null && b === null) return true;
234823
234823
  if (a === void 0 && b === void 0) return true;
234824
234824
  if ((a === null || a === void 0) !== (b === null || b === void 0)) {
234825
- differences.push(`Null/undefined mismatch at ${path4}`);
234825
+ differences.push(`Null/undefined mismatch at ${path5}`);
234826
234826
  return false;
234827
234827
  }
234828
234828
  if (Array.isArray(a) && Array.isArray(b)) {
234829
- return compareArrays(path4, a, b);
234829
+ return compareArrays(path5, a, b);
234830
234830
  }
234831
234831
  if (Array.isArray(a) !== Array.isArray(b)) {
234832
- differences.push(`Array type mismatch at ${path4}`);
234832
+ differences.push(`Array type mismatch at ${path5}`);
234833
234833
  return false;
234834
234834
  }
234835
234835
  if (typeof a === "object" && typeof b === "object") {
234836
- return compareObjects(path4, a, b);
234836
+ return compareObjects(path5, a, b);
234837
234837
  }
234838
- return comparePrimitive(path4, a, b);
234838
+ return comparePrimitive(path5, a, b);
234839
234839
  };
234840
234840
  comparePrimitive("id", original.id, generated.id);
234841
234841
  comparePrimitive("name", original.name, generated.name);
@@ -235010,34 +235010,34 @@ function generateMultiPlaceholderString(value, jsonPath, tracker) {
235010
235010
  }
235011
235011
  return value;
235012
235012
  }
235013
- function isJsonSchemaPath(path4, context) {
235014
- if (path4.endsWith("contextConfig.headersSchema") || path4.endsWith("responseSchema")) {
235013
+ function isJsonSchemaPath(path5, context) {
235014
+ if (path5.endsWith("contextConfig.headersSchema") || path5.endsWith("responseSchema")) {
235015
235015
  return true;
235016
235016
  }
235017
- if (path4.endsWith("headersSchema") && path4.length > "headersSchema".length) {
235017
+ if (path5.endsWith("headersSchema") && path5.length > "headersSchema".length) {
235018
235018
  return true;
235019
235019
  }
235020
- if (path4.includes("artifactComponents") && path4.endsWith("props")) {
235020
+ if (path5.includes("artifactComponents") && path5.endsWith("props")) {
235021
235021
  return true;
235022
235022
  }
235023
- if (path4.includes("dataComponents") && path4.endsWith("props")) {
235023
+ if (path5.includes("dataComponents") && path5.endsWith("props")) {
235024
235024
  return true;
235025
235025
  }
235026
- if (path4.includes("statusComponents") && path4.endsWith("detailsSchema")) {
235026
+ if (path5.includes("statusComponents") && path5.endsWith("detailsSchema")) {
235027
235027
  return true;
235028
235028
  }
235029
- if (path4.endsWith("inputSchema") || path4.endsWith("outputSchema")) {
235029
+ if (path5.endsWith("inputSchema") || path5.endsWith("outputSchema")) {
235030
235030
  return true;
235031
235031
  }
235032
235032
  if (context?.fileType) {
235033
- if (path4 === "props" && (context.fileType === "dataComponent" || context.fileType === "artifactComponent")) {
235033
+ if (path5 === "props" && (context.fileType === "dataComponent" || context.fileType === "artifactComponent")) {
235034
235034
  return true;
235035
235035
  }
235036
- if (path4 === "detailsSchema" && context.fileType === "statusComponent") {
235036
+ if (path5 === "detailsSchema" && context.fileType === "statusComponent") {
235037
235037
  return true;
235038
235038
  }
235039
235039
  if (context.fileType === "contextConfig") {
235040
- if (path4 === "headersSchema" || path4.endsWith("responseSchema")) {
235040
+ if (path5 === "headersSchema" || path5.endsWith("responseSchema")) {
235041
235041
  return true;
235042
235042
  }
235043
235043
  }
@@ -235048,16 +235048,16 @@ function updateTracker(tracker, placeholder, value) {
235048
235048
  tracker.placeholderToValue.set(placeholder, value);
235049
235049
  tracker.valueToPlaceholder.set(value, placeholder);
235050
235050
  }
235051
- function processObject(obj, tracker, path4 = "", context) {
235051
+ function processObject(obj, tracker, path5 = "", context) {
235052
235052
  if (typeof obj === "string") {
235053
235053
  if (containsTemplateLiterals(obj)) {
235054
- return generateMultiPlaceholderString(obj, path4, tracker);
235054
+ return generateMultiPlaceholderString(obj, path5, tracker);
235055
235055
  } else {
235056
235056
  const existingPlaceholder = tracker.valueToPlaceholder.get(obj);
235057
235057
  if (existingPlaceholder) {
235058
235058
  return existingPlaceholder;
235059
235059
  }
235060
- const placeholder = generatePlaceholder(path4);
235060
+ const placeholder = generatePlaceholder(path5);
235061
235061
  if (shouldReplaceString(obj, placeholder)) {
235062
235062
  const existingValue = tracker.placeholderToValue.get(placeholder);
235063
235063
  if (existingValue && existingValue !== obj) {
@@ -235071,7 +235071,7 @@ function processObject(obj, tracker, path4 = "", context) {
235071
235071
  }
235072
235072
  return obj;
235073
235073
  }
235074
- if (isJsonSchemaPath(path4, context)) {
235074
+ if (isJsonSchemaPath(path5, context)) {
235075
235075
  try {
235076
235076
  const zodSchema = jsonSchemaToZod(obj);
235077
235077
  return zodSchema;
@@ -235080,12 +235080,12 @@ function processObject(obj, tracker, path4 = "", context) {
235080
235080
  }
235081
235081
  }
235082
235082
  if (Array.isArray(obj)) {
235083
- return obj.map((item, index2) => processObject(item, tracker, `${path4}[${index2}]`, context));
235083
+ return obj.map((item, index2) => processObject(item, tracker, `${path5}[${index2}]`, context));
235084
235084
  }
235085
235085
  if (obj && typeof obj === "object") {
235086
235086
  const result = {};
235087
235087
  for (const [key, value] of Object.entries(obj)) {
235088
- const currentPath = path4 ? `${path4}.${key}` : key;
235088
+ const currentPath = path5 ? `${path5}.${key}` : key;
235089
235089
  result[key] = processObject(value, tracker, currentPath, context);
235090
235090
  }
235091
235091
  return result;
@@ -236434,11 +236434,11 @@ Now generate all ${fileSpecs.length} files following this exact format.`;
236434
236434
  if (debug) {
236435
236435
  console.log(`[DEBUG] Successfully extracted ${extractedFiles.length} files`);
236436
236436
  }
236437
- for (const { path: path4, content } of extractedFiles) {
236437
+ for (const { path: path5, content } of extractedFiles) {
236438
236438
  const cleanedContent = cleanGeneratedCode(content);
236439
- writeFileSync3(path4, cleanedContent);
236439
+ writeFileSync3(path5, cleanedContent);
236440
236440
  if (debug) {
236441
- console.log(`[DEBUG] Wrote file: ${path4} (${cleanedContent.length} chars)`);
236441
+ console.log(`[DEBUG] Wrote file: ${path5} (${cleanedContent.length} chars)`);
236442
236442
  }
236443
236443
  }
236444
236444
  if (debug) {
@@ -238314,6 +238314,7 @@ import { Command } from "commander";
238314
238314
  // src/commands/add.ts
238315
238315
  init_esm_shims();
238316
238316
  init_src();
238317
+ import path4 from "path";
238317
238318
  import * as p from "@clack/prompts";
238318
238319
  import chalk from "chalk";
238319
238320
  import { findUp } from "find-up";
@@ -238338,6 +238339,21 @@ async function cloneTemplate(templatePath, targetPath, replacements) {
238338
238339
  process.exit(1);
238339
238340
  }
238340
238341
  }
238342
+ async function cloneTemplateLocal(templatePath, targetPath, replacements) {
238343
+ await fs2.mkdir(targetPath, { recursive: true });
238344
+ try {
238345
+ await fs2.copy(templatePath, targetPath, {
238346
+ overwrite: true,
238347
+ errorOnExist: false
238348
+ });
238349
+ if (replacements && replacements.length > 0) {
238350
+ await replaceContentInFiles(targetPath, replacements);
238351
+ }
238352
+ } catch (error) {
238353
+ console.error(`Failed to clone template from ${templatePath}:`, error);
238354
+ process.exit(1);
238355
+ }
238356
+ }
238341
238357
  async function replaceContentInFiles(targetPath, replacements) {
238342
238358
  for (const replacement of replacements) {
238343
238359
  const filePath = path3.join(targetPath, replacement.filePath);
@@ -238492,12 +238508,25 @@ function injectPropertyIntoObject(content, propertyPath, replacement) {
238492
238508
  console.warn(`Could not inject property "${propertyPath}" - no suitable object found in content`);
238493
238509
  return content;
238494
238510
  }
238495
- async function getAvailableTemplates(templatePath = "template-projects") {
238496
- const response = await fetch(
238497
- `https://api.github.com/repos/inkeep/agents-cookbook/contents/${templatePath}`
238498
- );
238499
- const contents = await response.json();
238500
- return contents.filter((item) => item.type === "dir").map((item) => item.name);
238511
+ async function getAvailableTemplates(templatePath = "template-projects", local) {
238512
+ if (local && local.length > 0) {
238513
+ const fullTemplatePath = path3.join(local, templatePath);
238514
+ const items = await fs2.readdir(fullTemplatePath);
238515
+ const directories = [];
238516
+ for (const item of items) {
238517
+ const stat = await fs2.stat(path3.join(fullTemplatePath, item));
238518
+ if (stat.isDirectory() && item !== "weather-project") {
238519
+ directories.push(item);
238520
+ }
238521
+ }
238522
+ return directories;
238523
+ } else {
238524
+ const response = await fetch(
238525
+ `https://api.github.com/repos/inkeep/agents/contents/agents-cookbook/${templatePath}`
238526
+ );
238527
+ const contents = await response.json();
238528
+ return contents.filter((item) => item.type === "dir" && item.name !== "weather-project").map((item) => item.name);
238529
+ }
238501
238530
  }
238502
238531
 
238503
238532
  // src/commands/add.ts
@@ -238535,8 +238564,8 @@ var defaultAnthropicModelConfigurations = {
238535
238564
  }
238536
238565
  };
238537
238566
  async function addCommand(options) {
238538
- const projectTemplates = await getAvailableTemplates("template-projects");
238539
- const mcpTemplates = await getAvailableTemplates("template-mcps");
238567
+ const projectTemplates = await getAvailableTemplates("template-projects", options.localPrefix);
238568
+ const mcpTemplates = await getAvailableTemplates("template-mcps", options.localPrefix);
238540
238569
  if (!options.project && !options.mcp) {
238541
238570
  console.log(chalk.yellow("Available project templates:"));
238542
238571
  for (const template of projectTemplates) {
@@ -238559,17 +238588,17 @@ async function addCommand(options) {
238559
238588
  const s = p.spinner();
238560
238589
  s.start("Adding template...");
238561
238590
  if (options.project) {
238562
- await addProjectTemplate(options.project, options.targetPath);
238563
- s.stop(`Project template "${options.project}" added to ${options.targetPath}`);
238591
+ await addProjectTemplate(options.project, options.targetPath, options.localPrefix);
238592
+ s.stop();
238564
238593
  }
238565
238594
  if (options.mcp) {
238566
- await addMcpTemplate(options.mcp, options.targetPath, s);
238595
+ await addMcpTemplate(options.mcp, options.targetPath, s, options.localPrefix);
238567
238596
  }
238568
238597
  return;
238569
238598
  }
238570
238599
  }
238571
- async function addProjectTemplate(template, targetPath) {
238572
- const templates = await getAvailableTemplates();
238600
+ async function addProjectTemplate(template, targetPath, localPrefix) {
238601
+ const templates = await getAvailableTemplates("template-projects", localPrefix);
238573
238602
  if (!template) {
238574
238603
  console.log(chalk.yellow("Available templates:"));
238575
238604
  for (const template2 of templates) {
@@ -238623,14 +238652,19 @@ async function addProjectTemplate(template, targetPath) {
238623
238652
  }
238624
238653
  const s = p.spinner();
238625
238654
  s.start("Adding template...");
238626
- const fullTemplatePath = `https://github.com/inkeep/agents-cookbook/template-projects/${template}`;
238627
- await cloneTemplate(fullTemplatePath, templateDir, contentReplacements);
238655
+ if (localPrefix && localPrefix.length > 0) {
238656
+ const fullTemplatePath = path4.join(localPrefix, "template-projects", template);
238657
+ await cloneTemplateLocal(fullTemplatePath, templateDir, contentReplacements);
238658
+ } else {
238659
+ const fullTemplatePath = `https://github.com/inkeep/agents/agents-cookbook/template-projects/${template}`;
238660
+ await cloneTemplate(fullTemplatePath, templateDir, contentReplacements);
238661
+ }
238628
238662
  s.stop(`Template "${template}" added to ${templateDir}`);
238629
238663
  return;
238630
238664
  }
238631
238665
  }
238632
- async function addMcpTemplate(template, targetPath, s) {
238633
- const templates = await getAvailableTemplates("template-mcps");
238666
+ async function addMcpTemplate(template, targetPath, spinner8, localPrefix) {
238667
+ const templates = await getAvailableTemplates("template-mcps", localPrefix);
238634
238668
  if (!template) {
238635
238669
  console.log(chalk.yellow("Available templates:"));
238636
238670
  for (const template2 of templates) {
@@ -238642,9 +238676,14 @@ async function addMcpTemplate(template, targetPath, s) {
238642
238676
  const foundPath = await findAppDirectory();
238643
238677
  targetPath = `${foundPath}/${template}`;
238644
238678
  }
238645
- const fullTemplatePath = `https://github.com/inkeep/agents-cookbook/template-mcps/${template}`;
238646
- await cloneTemplate(fullTemplatePath, targetPath);
238647
- s.stop(`MCP template "${template}" added to ${targetPath}`);
238679
+ if (localPrefix && localPrefix.length > 0) {
238680
+ const fullTemplatePath = path4.join(localPrefix, "template-mcps", template);
238681
+ await cloneTemplateLocal(fullTemplatePath, targetPath);
238682
+ } else {
238683
+ const fullTemplatePath = `https://github.com/inkeep/agents/agents-cookbook/template-mcps/${template}`;
238684
+ await cloneTemplate(fullTemplatePath, targetPath);
238685
+ }
238686
+ spinner8.stop(`MCP template "${template}" added to ${targetPath}`);
238648
238687
  }
238649
238688
  async function findAppDirectory() {
238650
238689
  const appDirectory = await findUp("apps/mcp/app", { type: "directory" });
@@ -239038,8 +239077,8 @@ This project can be deployed to any platform that supports Next.js:
239038
239077
  }
239039
239078
  }
239040
239079
  async function devCommand(options) {
239041
- const { port, host, build, outputDir, path: path4, export: exportFlag, openBrowser } = options;
239042
- if (path4) {
239080
+ const { port, host, build, outputDir, path: path5, export: exportFlag, openBrowser } = options;
239081
+ if (path5) {
239043
239082
  const rt = resolveWebRuntime(true);
239044
239083
  console.log(rt);
239045
239084
  return;
@@ -240772,11 +240811,11 @@ var packageJsonPath = join14(__dirname3, "..", "package.json");
240772
240811
  var packageJson = JSON.parse(readFileSync7(packageJsonPath, "utf-8"));
240773
240812
  var program = new Command();
240774
240813
  program.name("inkeep").description("CLI tool for Inkeep Agent Framework").version(packageJson.version);
240775
- program.command("add [template]").description("Add a new template to the project").option("--project <template>", "Project template to add").option("--mcp <template>", "MCP template to add").option("--target-path <path>", "Target path to add the template to").option("--config <path>", "Path to configuration file").action(async (template, options) => {
240814
+ program.command("add [template]").description("Add a new template to the project").option("--project <template>", "Project template to add").option("--mcp <template>", "MCP template to add").option("--target-path <path>", "Target path to add the template to").option("--local-prefix <path_prefix>", "Use local templates from the given path prefix").option("--config <path>", "Path to configuration file").action(async (template, options) => {
240776
240815
  await addCommand({ template, ...options });
240777
240816
  });
240778
- program.command("init [path]").description("Initialize a new Inkeep configuration file").option("--no-interactive", "Skip interactive path selection").option("--config <path>", "Path to use as template for new configuration").action(async (path4, options) => {
240779
- await initCommand({ path: path4, ...options });
240817
+ program.command("init [path]").description("Initialize a new Inkeep configuration file").option("--no-interactive", "Skip interactive path selection").option("--config <path>", "Path to use as template for new configuration").action(async (path5, options) => {
240818
+ await initCommand({ path: path5, ...options });
240780
240819
  });
240781
240820
  var configCommand = program.command("config").description("Manage Inkeep configuration");
240782
240821
  configCommand.command("get [key]").description("Get configuration value(s)").option("--config <path>", "Path to configuration file").option("--config-file-path <path>", "Path to configuration file (deprecated, use --config)").action(async (key, options) => {