@getmikk/cli 1.3.1 → 1.3.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +103 -109
- package/dist/index.js.map +4 -4
- package/package.json +11 -10
package/dist/index.js
CHANGED
|
@@ -7228,7 +7228,7 @@ var require_typescript = __commonJS({
|
|
|
7228
7228
|
usingSingleLineStringWriter: () => usingSingleLineStringWriter,
|
|
7229
7229
|
utf16EncodeAsString: () => utf16EncodeAsString,
|
|
7230
7230
|
validateLocaleAndSetLanguage: () => validateLocaleAndSetLanguage,
|
|
7231
|
-
version: () =>
|
|
7231
|
+
version: () => version,
|
|
7232
7232
|
versionMajorMinor: () => versionMajorMinor,
|
|
7233
7233
|
visitArray: () => visitArray,
|
|
7234
7234
|
visitCommaListElements: () => visitCommaListElements,
|
|
@@ -7252,7 +7252,7 @@ var require_typescript = __commonJS({
|
|
|
7252
7252
|
});
|
|
7253
7253
|
module3.exports = __toCommonJS(typescript_exports);
|
|
7254
7254
|
var versionMajorMinor = "5.9";
|
|
7255
|
-
var
|
|
7255
|
+
var version = "5.9.3";
|
|
7256
7256
|
var Comparison = /* @__PURE__ */ ((Comparison3) => {
|
|
7257
7257
|
Comparison3[Comparison3["LessThan"] = -1] = "LessThan";
|
|
7258
7258
|
Comparison3[Comparison3["EqualTo"] = 0] = "EqualTo";
|
|
@@ -9885,9 +9885,9 @@ ${lanes.join("\n")}
|
|
|
9885
9885
|
* Tests whether a version matches the range. This is equivalent to `satisfies(version, range, { includePrerelease: true })`.
|
|
9886
9886
|
* in `node-semver`.
|
|
9887
9887
|
*/
|
|
9888
|
-
test(
|
|
9889
|
-
if (typeof
|
|
9890
|
-
return testDisjunction(
|
|
9888
|
+
test(version2) {
|
|
9889
|
+
if (typeof version2 === "string") version2 = new Version(version2);
|
|
9890
|
+
return testDisjunction(version2, this._alternatives);
|
|
9891
9891
|
}
|
|
9892
9892
|
toString() {
|
|
9893
9893
|
return formatDisjunction(this._alternatives);
|
|
@@ -9921,14 +9921,14 @@ ${lanes.join("\n")}
|
|
|
9921
9921
|
const match = partialRegExp.exec(text);
|
|
9922
9922
|
if (!match) return void 0;
|
|
9923
9923
|
const [, major, minor = "*", patch = "*", prerelease, build2] = match;
|
|
9924
|
-
const
|
|
9924
|
+
const version2 = new Version(
|
|
9925
9925
|
isWildcard(major) ? 0 : parseInt(major, 10),
|
|
9926
9926
|
isWildcard(major) || isWildcard(minor) ? 0 : parseInt(minor, 10),
|
|
9927
9927
|
isWildcard(major) || isWildcard(minor) || isWildcard(patch) ? 0 : parseInt(patch, 10),
|
|
9928
9928
|
prerelease,
|
|
9929
9929
|
build2
|
|
9930
9930
|
);
|
|
9931
|
-
return { version:
|
|
9931
|
+
return { version: version2, major, minor, patch };
|
|
9932
9932
|
}
|
|
9933
9933
|
function parseHyphen(left, right, comparators) {
|
|
9934
9934
|
const leftResult = parsePartial(left);
|
|
@@ -9948,46 +9948,46 @@ ${lanes.join("\n")}
|
|
|
9948
9948
|
function parseComparator(operator, text, comparators) {
|
|
9949
9949
|
const result = parsePartial(text);
|
|
9950
9950
|
if (!result) return false;
|
|
9951
|
-
const { version:
|
|
9951
|
+
const { version: version2, major, minor, patch } = result;
|
|
9952
9952
|
if (!isWildcard(major)) {
|
|
9953
9953
|
switch (operator) {
|
|
9954
9954
|
case "~":
|
|
9955
|
-
comparators.push(createComparator(">=",
|
|
9955
|
+
comparators.push(createComparator(">=", version2));
|
|
9956
9956
|
comparators.push(createComparator(
|
|
9957
9957
|
"<",
|
|
9958
|
-
|
|
9958
|
+
version2.increment(
|
|
9959
9959
|
isWildcard(minor) ? "major" : "minor"
|
|
9960
9960
|
)
|
|
9961
9961
|
));
|
|
9962
9962
|
break;
|
|
9963
9963
|
case "^":
|
|
9964
|
-
comparators.push(createComparator(">=",
|
|
9964
|
+
comparators.push(createComparator(">=", version2));
|
|
9965
9965
|
comparators.push(createComparator(
|
|
9966
9966
|
"<",
|
|
9967
|
-
|
|
9968
|
-
|
|
9967
|
+
version2.increment(
|
|
9968
|
+
version2.major > 0 || isWildcard(minor) ? "major" : version2.minor > 0 || isWildcard(patch) ? "minor" : "patch"
|
|
9969
9969
|
)
|
|
9970
9970
|
));
|
|
9971
9971
|
break;
|
|
9972
9972
|
case "<":
|
|
9973
9973
|
case ">=":
|
|
9974
9974
|
comparators.push(
|
|
9975
|
-
isWildcard(minor) || isWildcard(patch) ? createComparator(operator,
|
|
9975
|
+
isWildcard(minor) || isWildcard(patch) ? createComparator(operator, version2.with({ prerelease: "0" })) : createComparator(operator, version2)
|
|
9976
9976
|
);
|
|
9977
9977
|
break;
|
|
9978
9978
|
case "<=":
|
|
9979
9979
|
case ">":
|
|
9980
9980
|
comparators.push(
|
|
9981
|
-
isWildcard(minor) ? createComparator(operator === "<=" ? "<" : ">=",
|
|
9981
|
+
isWildcard(minor) ? createComparator(operator === "<=" ? "<" : ">=", version2.increment("major").with({ prerelease: "0" })) : isWildcard(patch) ? createComparator(operator === "<=" ? "<" : ">=", version2.increment("minor").with({ prerelease: "0" })) : createComparator(operator, version2)
|
|
9982
9982
|
);
|
|
9983
9983
|
break;
|
|
9984
9984
|
case "=":
|
|
9985
9985
|
case void 0:
|
|
9986
9986
|
if (isWildcard(minor) || isWildcard(patch)) {
|
|
9987
|
-
comparators.push(createComparator(">=",
|
|
9988
|
-
comparators.push(createComparator("<",
|
|
9987
|
+
comparators.push(createComparator(">=", version2.with({ prerelease: "0" })));
|
|
9988
|
+
comparators.push(createComparator("<", version2.increment(isWildcard(minor) ? "major" : "minor").with({ prerelease: "0" })));
|
|
9989
9989
|
} else {
|
|
9990
|
-
comparators.push(createComparator("=",
|
|
9990
|
+
comparators.push(createComparator("=", version2));
|
|
9991
9991
|
}
|
|
9992
9992
|
break;
|
|
9993
9993
|
default:
|
|
@@ -10004,21 +10004,21 @@ ${lanes.join("\n")}
|
|
|
10004
10004
|
function createComparator(operator, operand) {
|
|
10005
10005
|
return { operator, operand };
|
|
10006
10006
|
}
|
|
10007
|
-
function testDisjunction(
|
|
10007
|
+
function testDisjunction(version2, alternatives) {
|
|
10008
10008
|
if (alternatives.length === 0) return true;
|
|
10009
10009
|
for (const alternative of alternatives) {
|
|
10010
|
-
if (testAlternative(
|
|
10010
|
+
if (testAlternative(version2, alternative)) return true;
|
|
10011
10011
|
}
|
|
10012
10012
|
return false;
|
|
10013
10013
|
}
|
|
10014
|
-
function testAlternative(
|
|
10014
|
+
function testAlternative(version2, comparators) {
|
|
10015
10015
|
for (const comparator of comparators) {
|
|
10016
|
-
if (!testComparator(
|
|
10016
|
+
if (!testComparator(version2, comparator.operator, comparator.operand)) return false;
|
|
10017
10017
|
}
|
|
10018
10018
|
return true;
|
|
10019
10019
|
}
|
|
10020
|
-
function testComparator(
|
|
10021
|
-
const cmp =
|
|
10020
|
+
function testComparator(version2, operator, operand) {
|
|
10021
|
+
const cmp = version2.compareTo(operand);
|
|
10022
10022
|
switch (operator) {
|
|
10023
10023
|
case "<":
|
|
10024
10024
|
return cmp < 0;
|
|
@@ -52241,7 +52241,7 @@ ${lanes.join("\n")}
|
|
|
52241
52241
|
}
|
|
52242
52242
|
var typeScriptVersion;
|
|
52243
52243
|
function getPackageJsonTypesVersionsPaths(typesVersions) {
|
|
52244
|
-
if (!typeScriptVersion) typeScriptVersion = new Version(
|
|
52244
|
+
if (!typeScriptVersion) typeScriptVersion = new Version(version);
|
|
52245
52245
|
for (const key in typesVersions) {
|
|
52246
52246
|
if (!hasProperty(typesVersions, key)) continue;
|
|
52247
52247
|
const keyRange = VersionRange.tryParse(key);
|
|
@@ -53789,9 +53789,9 @@ ${lanes.join("\n")}
|
|
|
53789
53789
|
state
|
|
53790
53790
|
);
|
|
53791
53791
|
if (peerPackageJson) {
|
|
53792
|
-
const
|
|
53793
|
-
result += `+${key}@${
|
|
53794
|
-
if (state.traceEnabled) trace(state.host, Diagnostics.Found_peerDependency_0_with_1_version, key,
|
|
53792
|
+
const version2 = peerPackageJson.contents.packageJsonContent.version;
|
|
53793
|
+
result += `+${key}@${version2}`;
|
|
53794
|
+
if (state.traceEnabled) trace(state.host, Diagnostics.Found_peerDependency_0_with_1_version, key, version2);
|
|
53795
53795
|
} else {
|
|
53796
53796
|
if (state.traceEnabled) trace(state.host, Diagnostics.Failed_to_find_peerDependency_0, key);
|
|
53797
53797
|
}
|
|
@@ -53889,7 +53889,7 @@ ${lanes.join("\n")}
|
|
|
53889
53889
|
false
|
|
53890
53890
|
);
|
|
53891
53891
|
if (state.traceEnabled) {
|
|
53892
|
-
trace(state.host, Diagnostics.package_json_has_a_typesVersions_entry_0_that_matches_compiler_version_1_looking_for_a_pattern_to_match_module_name_2, versionPaths.version,
|
|
53892
|
+
trace(state.host, Diagnostics.package_json_has_a_typesVersions_entry_0_that_matches_compiler_version_1_looking_for_a_pattern_to_match_module_name_2, versionPaths.version, version, moduleName);
|
|
53893
53893
|
}
|
|
53894
53894
|
const pathPatterns = tryParsePatterns(versionPaths.paths);
|
|
53895
53895
|
const result = tryLoadModuleUsingPaths(extensions, moduleName, candidate, versionPaths.paths, pathPatterns, loader, onlyRecordFailuresForPackageFile || onlyRecordFailuresForIndex, state);
|
|
@@ -54371,7 +54371,7 @@ ${lanes.join("\n")}
|
|
|
54371
54371
|
if (!startsWith(key, "types@")) return false;
|
|
54372
54372
|
const range = VersionRange.tryParse(key.substring("types@".length));
|
|
54373
54373
|
if (!range) return false;
|
|
54374
|
-
return range.test(
|
|
54374
|
+
return range.test(version);
|
|
54375
54375
|
}
|
|
54376
54376
|
function loadModuleFromNearestNodeModulesDirectory(extensions, moduleName, directory, state, cache, redirectedReference) {
|
|
54377
54377
|
return loadModuleFromNearestNodeModulesDirectoryWorker(
|
|
@@ -54507,7 +54507,7 @@ ${lanes.join("\n")}
|
|
|
54507
54507
|
const versionPaths = rest !== "" && packageInfo ? getVersionPathsOfPackageJsonInfo(packageInfo, state) : void 0;
|
|
54508
54508
|
if (versionPaths) {
|
|
54509
54509
|
if (state.traceEnabled) {
|
|
54510
|
-
trace(state.host, Diagnostics.package_json_has_a_typesVersions_entry_0_that_matches_compiler_version_1_looking_for_a_pattern_to_match_module_name_2, versionPaths.version,
|
|
54510
|
+
trace(state.host, Diagnostics.package_json_has_a_typesVersions_entry_0_that_matches_compiler_version_1_looking_for_a_pattern_to_match_module_name_2, versionPaths.version, version, rest);
|
|
54511
54511
|
}
|
|
54512
54512
|
const packageDirectoryExists = nodeModulesDirectoryExists && directoryProbablyExists(packageDirectory, state.host);
|
|
54513
54513
|
const pathPatterns = tryParsePatterns(versionPaths.paths);
|
|
@@ -134422,7 +134422,7 @@ ${lanes.join("\n")}
|
|
|
134422
134422
|
emitSkipped = true;
|
|
134423
134423
|
return;
|
|
134424
134424
|
}
|
|
134425
|
-
const buildInfo = host.getBuildInfo() || { version
|
|
134425
|
+
const buildInfo = host.getBuildInfo() || { version };
|
|
134426
134426
|
writeFile7(
|
|
134427
134427
|
host,
|
|
134428
134428
|
emitterDiagnostics,
|
|
@@ -144302,7 +144302,7 @@ ${lanes.join("\n")}
|
|
|
144302
144302
|
const useOldState = canReuseOldState(referencedMap, oldState);
|
|
144303
144303
|
newProgram.getTypeChecker();
|
|
144304
144304
|
for (const sourceFile of newProgram.getSourceFiles()) {
|
|
144305
|
-
const
|
|
144305
|
+
const version2 = Debug.checkDefined(sourceFile.version, "Program intended to be used with Builder should have source files with versions set");
|
|
144306
144306
|
const oldUncommittedSignature = useOldState ? (_a = oldState.oldSignatures) == null ? void 0 : _a.get(sourceFile.resolvedPath) : void 0;
|
|
144307
144307
|
const signature = oldUncommittedSignature === void 0 ? useOldState ? (_b = oldState.fileInfos.get(sourceFile.resolvedPath)) == null ? void 0 : _b.signature : void 0 : oldUncommittedSignature || void 0;
|
|
144308
144308
|
if (referencedMap) {
|
|
@@ -144312,7 +144312,7 @@ ${lanes.join("\n")}
|
|
|
144312
144312
|
}
|
|
144313
144313
|
}
|
|
144314
144314
|
fileInfos.set(sourceFile.resolvedPath, {
|
|
144315
|
-
version:
|
|
144315
|
+
version: version2,
|
|
144316
144316
|
signature,
|
|
144317
144317
|
// No need to calculate affectsGlobalScope with --out since its not used at all
|
|
144318
144318
|
affectsGlobalScope: !options.outFile ? isFileAffectingGlobalScope(sourceFile) || void 0 : void 0,
|
|
@@ -145116,7 +145116,7 @@ ${lanes.join("\n")}
|
|
|
145116
145116
|
root: arrayFrom(rootFileNames, (r) => relativeToBuildInfo(r)),
|
|
145117
145117
|
errors: state.hasErrors ? true : void 0,
|
|
145118
145118
|
checkPending: state.checkPending,
|
|
145119
|
-
version
|
|
145119
|
+
version
|
|
145120
145120
|
};
|
|
145121
145121
|
return buildInfo2;
|
|
145122
145122
|
}
|
|
@@ -145148,7 +145148,7 @@ ${lanes.join("\n")}
|
|
|
145148
145148
|
// Actual value
|
|
145149
145149
|
errors: state.hasErrors ? true : void 0,
|
|
145150
145150
|
checkPending: state.checkPending,
|
|
145151
|
-
version
|
|
145151
|
+
version
|
|
145152
145152
|
};
|
|
145153
145153
|
return buildInfo2;
|
|
145154
145154
|
}
|
|
@@ -145245,7 +145245,7 @@ ${lanes.join("\n")}
|
|
|
145245
145245
|
latestChangedDtsFile,
|
|
145246
145246
|
errors: state.hasErrors ? true : void 0,
|
|
145247
145247
|
checkPending: state.checkPending,
|
|
145248
|
-
version
|
|
145248
|
+
version
|
|
145249
145249
|
};
|
|
145250
145250
|
return buildInfo;
|
|
145251
145251
|
function relativeToBuildInfoEnsuringAbsolutePath(path19) {
|
|
@@ -146022,8 +146022,8 @@ ${lanes.join("\n")}
|
|
|
146022
146022
|
const resolvedRoots = new Map(program3.resolvedRoot);
|
|
146023
146023
|
program3.fileInfos.forEach((fileInfo, index) => {
|
|
146024
146024
|
const path19 = toPath(program3.fileNames[index], buildInfoDirectory, getCanonicalFileName);
|
|
146025
|
-
const
|
|
146026
|
-
fileInfos.set(path19,
|
|
146025
|
+
const version2 = isString(fileInfo) ? fileInfo : fileInfo.version;
|
|
146026
|
+
fileInfos.set(path19, version2);
|
|
146027
146027
|
if (rootIndex < program3.root.length) {
|
|
146028
146028
|
const current = program3.root[rootIndex];
|
|
146029
146029
|
const fileId = index + 1;
|
|
@@ -147922,7 +147922,7 @@ ${lanes.join("\n")}
|
|
|
147922
147922
|
if (!content) return void 0;
|
|
147923
147923
|
buildInfo = getBuildInfo(buildInfoPath, content);
|
|
147924
147924
|
}
|
|
147925
|
-
if (!buildInfo || buildInfo.version !==
|
|
147925
|
+
if (!buildInfo || buildInfo.version !== version || !isIncrementalBuildInfo(buildInfo)) return void 0;
|
|
147926
147926
|
return createBuilderProgramUsingIncrementalBuildInfo(buildInfo, buildInfoPath, host);
|
|
147927
147927
|
}
|
|
147928
147928
|
function createIncrementalCompilerHost(options, system = sys) {
|
|
@@ -149624,7 +149624,7 @@ ${lanes.join("\n")}
|
|
|
149624
149624
|
};
|
|
149625
149625
|
}
|
|
149626
149626
|
const incrementalBuildInfo = isIncremental && isIncrementalBuildInfo(buildInfo) ? buildInfo : void 0;
|
|
149627
|
-
if ((incrementalBuildInfo || !isIncremental) && buildInfo.version !==
|
|
149627
|
+
if ((incrementalBuildInfo || !isIncremental) && buildInfo.version !== version) {
|
|
149628
149628
|
return {
|
|
149629
149629
|
type: 14,
|
|
149630
149630
|
version: buildInfo.version
|
|
@@ -149680,17 +149680,17 @@ ${lanes.join("\n")}
|
|
|
149680
149680
|
}
|
|
149681
149681
|
const inputPath = toPath2(state, inputFile);
|
|
149682
149682
|
if (buildInfoTime < inputTime) {
|
|
149683
|
-
let
|
|
149683
|
+
let version2;
|
|
149684
149684
|
let currentVersion;
|
|
149685
149685
|
if (incrementalBuildInfo) {
|
|
149686
149686
|
if (!buildInfoVersionMap) buildInfoVersionMap = getBuildInfoFileVersionMap(incrementalBuildInfo, buildInfoPath, host);
|
|
149687
149687
|
const resolvedInputPath = buildInfoVersionMap.roots.get(inputPath);
|
|
149688
|
-
|
|
149689
|
-
const text =
|
|
149688
|
+
version2 = buildInfoVersionMap.fileInfos.get(resolvedInputPath ?? inputPath);
|
|
149689
|
+
const text = version2 ? state.readFileWithCache(resolvedInputPath ?? inputFile) : void 0;
|
|
149690
149690
|
currentVersion = text !== void 0 ? getSourceFileVersionAsHashFromText(host, text) : void 0;
|
|
149691
|
-
if (
|
|
149691
|
+
if (version2 && version2 === currentVersion) pseudoInputUpToDate = true;
|
|
149692
149692
|
}
|
|
149693
|
-
if (!
|
|
149693
|
+
if (!version2 || version2 !== currentVersion) {
|
|
149694
149694
|
return {
|
|
149695
149695
|
type: 5,
|
|
149696
149696
|
outOfDateOutputFileName: buildInfoPath,
|
|
@@ -150442,7 +150442,7 @@ ${lanes.join("\n")}
|
|
|
150442
150442
|
Diagnostics.Project_0_is_out_of_date_because_output_for_it_was_generated_with_version_1_that_differs_with_current_version_2,
|
|
150443
150443
|
relName(state, configFileName),
|
|
150444
150444
|
status.version,
|
|
150445
|
-
|
|
150445
|
+
version
|
|
150446
150446
|
);
|
|
150447
150447
|
case 17:
|
|
150448
150448
|
return reportStatus(
|
|
@@ -150528,7 +150528,7 @@ ${lanes.join("\n")}
|
|
|
150528
150528
|
return !!commandLine.options.all ? toSorted(optionDeclarations.concat(tscBuildOption), (a, b) => compareStringsCaseInsensitive(a.name, b.name)) : filter(optionDeclarations.concat(tscBuildOption), (v) => !!v.showInSimplifiedHelpView);
|
|
150529
150529
|
}
|
|
150530
150530
|
function printVersion(sys2) {
|
|
150531
|
-
sys2.write(getDiagnosticText(Diagnostics.Version_0,
|
|
150531
|
+
sys2.write(getDiagnosticText(Diagnostics.Version_0, version) + sys2.newLine);
|
|
150532
150532
|
}
|
|
150533
150533
|
function createColors(sys2) {
|
|
150534
150534
|
const showColors = defaultIsPretty(sys2);
|
|
@@ -150780,7 +150780,7 @@ ${lanes.join("\n")}
|
|
|
150780
150780
|
}
|
|
150781
150781
|
function printEasyHelp(sys2, simpleOptions) {
|
|
150782
150782
|
const colors = createColors(sys2);
|
|
150783
|
-
let output = [...getHeader(sys2, `${getDiagnosticText(Diagnostics.tsc_Colon_The_TypeScript_Compiler)} - ${getDiagnosticText(Diagnostics.Version_0,
|
|
150783
|
+
let output = [...getHeader(sys2, `${getDiagnosticText(Diagnostics.tsc_Colon_The_TypeScript_Compiler)} - ${getDiagnosticText(Diagnostics.Version_0, version)}`)];
|
|
150784
150784
|
output.push(colors.bold(getDiagnosticText(Diagnostics.COMMON_COMMANDS)) + sys2.newLine + sys2.newLine);
|
|
150785
150785
|
example("tsc", Diagnostics.Compiles_the_current_project_tsconfig_json_in_the_working_directory);
|
|
150786
150786
|
example("tsc app.ts util.ts", Diagnostics.Ignoring_tsconfig_json_compiles_the_specified_files_with_default_compiler_options);
|
|
@@ -150827,7 +150827,7 @@ ${lanes.join("\n")}
|
|
|
150827
150827
|
}
|
|
150828
150828
|
}
|
|
150829
150829
|
function printAllHelp(sys2, compilerOptions, buildOptions, watchOptions) {
|
|
150830
|
-
let output = [...getHeader(sys2, `${getDiagnosticText(Diagnostics.tsc_Colon_The_TypeScript_Compiler)} - ${getDiagnosticText(Diagnostics.Version_0,
|
|
150830
|
+
let output = [...getHeader(sys2, `${getDiagnosticText(Diagnostics.tsc_Colon_The_TypeScript_Compiler)} - ${getDiagnosticText(Diagnostics.Version_0, version)}`)];
|
|
150831
150831
|
output = [...output, ...generateSectionOptionsOutput(
|
|
150832
150832
|
sys2,
|
|
150833
150833
|
getDiagnosticText(Diagnostics.ALL_COMPILER_OPTIONS),
|
|
@@ -150859,7 +150859,7 @@ ${lanes.join("\n")}
|
|
|
150859
150859
|
}
|
|
150860
150860
|
}
|
|
150861
150861
|
function printBuildHelp(sys2, buildOptions) {
|
|
150862
|
-
let output = [...getHeader(sys2, `${getDiagnosticText(Diagnostics.tsc_Colon_The_TypeScript_Compiler)} - ${getDiagnosticText(Diagnostics.Version_0,
|
|
150862
|
+
let output = [...getHeader(sys2, `${getDiagnosticText(Diagnostics.tsc_Colon_The_TypeScript_Compiler)} - ${getDiagnosticText(Diagnostics.Version_0, version)}`)];
|
|
150863
150863
|
output = [...output, ...generateSectionOptionsOutput(
|
|
150864
150864
|
sys2,
|
|
150865
150865
|
getDiagnosticText(Diagnostics.BUILD_OPTIONS),
|
|
@@ -158382,38 +158382,38 @@ ${lanes.join("\n")}
|
|
|
158382
158382
|
}
|
|
158383
158383
|
return settingsOrHost;
|
|
158384
158384
|
}
|
|
158385
|
-
function acquireDocument(fileName, compilationSettings, scriptSnapshot,
|
|
158385
|
+
function acquireDocument(fileName, compilationSettings, scriptSnapshot, version2, scriptKind, languageVersionOrOptions) {
|
|
158386
158386
|
const path19 = toPath(fileName, currentDirectory, getCanonicalFileName);
|
|
158387
158387
|
const key = getKeyForCompilationSettings(getCompilationSettings(compilationSettings));
|
|
158388
|
-
return acquireDocumentWithKey(fileName, path19, compilationSettings, key, scriptSnapshot,
|
|
158388
|
+
return acquireDocumentWithKey(fileName, path19, compilationSettings, key, scriptSnapshot, version2, scriptKind, languageVersionOrOptions);
|
|
158389
158389
|
}
|
|
158390
|
-
function acquireDocumentWithKey(fileName, path19, compilationSettings, key, scriptSnapshot,
|
|
158390
|
+
function acquireDocumentWithKey(fileName, path19, compilationSettings, key, scriptSnapshot, version2, scriptKind, languageVersionOrOptions) {
|
|
158391
158391
|
return acquireOrUpdateDocument(
|
|
158392
158392
|
fileName,
|
|
158393
158393
|
path19,
|
|
158394
158394
|
compilationSettings,
|
|
158395
158395
|
key,
|
|
158396
158396
|
scriptSnapshot,
|
|
158397
|
-
|
|
158397
|
+
version2,
|
|
158398
158398
|
/*acquiring*/
|
|
158399
158399
|
true,
|
|
158400
158400
|
scriptKind,
|
|
158401
158401
|
languageVersionOrOptions
|
|
158402
158402
|
);
|
|
158403
158403
|
}
|
|
158404
|
-
function updateDocument(fileName, compilationSettings, scriptSnapshot,
|
|
158404
|
+
function updateDocument(fileName, compilationSettings, scriptSnapshot, version2, scriptKind, languageVersionOrOptions) {
|
|
158405
158405
|
const path19 = toPath(fileName, currentDirectory, getCanonicalFileName);
|
|
158406
158406
|
const key = getKeyForCompilationSettings(getCompilationSettings(compilationSettings));
|
|
158407
|
-
return updateDocumentWithKey(fileName, path19, compilationSettings, key, scriptSnapshot,
|
|
158407
|
+
return updateDocumentWithKey(fileName, path19, compilationSettings, key, scriptSnapshot, version2, scriptKind, languageVersionOrOptions);
|
|
158408
158408
|
}
|
|
158409
|
-
function updateDocumentWithKey(fileName, path19, compilationSettings, key, scriptSnapshot,
|
|
158409
|
+
function updateDocumentWithKey(fileName, path19, compilationSettings, key, scriptSnapshot, version2, scriptKind, languageVersionOrOptions) {
|
|
158410
158410
|
return acquireOrUpdateDocument(
|
|
158411
158411
|
fileName,
|
|
158412
158412
|
path19,
|
|
158413
158413
|
getCompilationSettings(compilationSettings),
|
|
158414
158414
|
key,
|
|
158415
158415
|
scriptSnapshot,
|
|
158416
|
-
|
|
158416
|
+
version2,
|
|
158417
158417
|
/*acquiring*/
|
|
158418
158418
|
false,
|
|
158419
158419
|
scriptKind,
|
|
@@ -158425,7 +158425,7 @@ ${lanes.join("\n")}
|
|
|
158425
158425
|
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}`);
|
|
158426
158426
|
return entry;
|
|
158427
158427
|
}
|
|
158428
|
-
function acquireOrUpdateDocument(fileName, path19, compilationSettingsOrHost, key, scriptSnapshot,
|
|
158428
|
+
function acquireOrUpdateDocument(fileName, path19, compilationSettingsOrHost, key, scriptSnapshot, version2, acquiring, scriptKind, languageVersionOrOptions) {
|
|
158429
158429
|
var _a, _b, _c, _d;
|
|
158430
158430
|
scriptKind = ensureScriptKind(fileName, scriptKind);
|
|
158431
158431
|
const compilationSettings = getCompilationSettings(compilationSettingsOrHost);
|
|
@@ -158469,7 +158469,7 @@ ${lanes.join("\n")}
|
|
|
158469
158469
|
fileName,
|
|
158470
158470
|
scriptSnapshot,
|
|
158471
158471
|
sourceFileOptions,
|
|
158472
|
-
|
|
158472
|
+
version2,
|
|
158473
158473
|
/*setNodeParents*/
|
|
158474
158474
|
false,
|
|
158475
158475
|
scriptKind
|
|
@@ -158483,8 +158483,8 @@ ${lanes.join("\n")}
|
|
|
158483
158483
|
};
|
|
158484
158484
|
setBucketEntry();
|
|
158485
158485
|
} else {
|
|
158486
|
-
if (entry.sourceFile.version !==
|
|
158487
|
-
entry.sourceFile = updateLanguageServiceSourceFile(entry.sourceFile, scriptSnapshot,
|
|
158486
|
+
if (entry.sourceFile.version !== version2) {
|
|
158487
|
+
entry.sourceFile = updateLanguageServiceSourceFile(entry.sourceFile, scriptSnapshot, version2, scriptSnapshot.getChangeRange(entry.sourceFile.scriptSnapshot));
|
|
158488
158488
|
if (externalCache) {
|
|
158489
158489
|
externalCache.setDocument(keyWithMode, path19, entry.sourceFile);
|
|
158490
158490
|
}
|
|
@@ -167314,7 +167314,7 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
|
|
|
167314
167314
|
throw new Error("Could not find file: '" + fileName + "'.");
|
|
167315
167315
|
}
|
|
167316
167316
|
const scriptKind = getScriptKind(fileName, this.host);
|
|
167317
|
-
const
|
|
167317
|
+
const version2 = this.host.getScriptVersion(fileName);
|
|
167318
167318
|
let sourceFile;
|
|
167319
167319
|
if (this.currentFileName !== fileName) {
|
|
167320
167320
|
const options = {
|
|
@@ -167334,17 +167334,17 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
|
|
|
167334
167334
|
fileName,
|
|
167335
167335
|
scriptSnapshot,
|
|
167336
167336
|
options,
|
|
167337
|
-
|
|
167337
|
+
version2,
|
|
167338
167338
|
/*setNodeParents*/
|
|
167339
167339
|
true,
|
|
167340
167340
|
scriptKind
|
|
167341
167341
|
);
|
|
167342
|
-
} else if (this.currentFileVersion !==
|
|
167342
|
+
} else if (this.currentFileVersion !== version2) {
|
|
167343
167343
|
const editRange = scriptSnapshot.getChangeRange(this.currentFileScriptSnapshot);
|
|
167344
|
-
sourceFile = updateLanguageServiceSourceFile(this.currentSourceFile, scriptSnapshot,
|
|
167344
|
+
sourceFile = updateLanguageServiceSourceFile(this.currentSourceFile, scriptSnapshot, version2, editRange);
|
|
167345
167345
|
}
|
|
167346
167346
|
if (sourceFile) {
|
|
167347
|
-
this.currentFileVersion =
|
|
167347
|
+
this.currentFileVersion = version2;
|
|
167348
167348
|
this.currentFileName = fileName;
|
|
167349
167349
|
this.currentFileScriptSnapshot = scriptSnapshot;
|
|
167350
167350
|
this.currentSourceFile = sourceFile;
|
|
@@ -167352,18 +167352,18 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
|
|
|
167352
167352
|
return this.currentSourceFile;
|
|
167353
167353
|
}
|
|
167354
167354
|
};
|
|
167355
|
-
function setSourceFileFields(sourceFile, scriptSnapshot,
|
|
167356
|
-
sourceFile.version =
|
|
167355
|
+
function setSourceFileFields(sourceFile, scriptSnapshot, version2) {
|
|
167356
|
+
sourceFile.version = version2;
|
|
167357
167357
|
sourceFile.scriptSnapshot = scriptSnapshot;
|
|
167358
167358
|
}
|
|
167359
|
-
function createLanguageServiceSourceFile(fileName, scriptSnapshot, scriptTargetOrOptions,
|
|
167359
|
+
function createLanguageServiceSourceFile(fileName, scriptSnapshot, scriptTargetOrOptions, version2, setNodeParents, scriptKind) {
|
|
167360
167360
|
const sourceFile = createSourceFile(fileName, getSnapshotText(scriptSnapshot), scriptTargetOrOptions, setNodeParents, scriptKind);
|
|
167361
|
-
setSourceFileFields(sourceFile, scriptSnapshot,
|
|
167361
|
+
setSourceFileFields(sourceFile, scriptSnapshot, version2);
|
|
167362
167362
|
return sourceFile;
|
|
167363
167363
|
}
|
|
167364
|
-
function updateLanguageServiceSourceFile(sourceFile, scriptSnapshot,
|
|
167364
|
+
function updateLanguageServiceSourceFile(sourceFile, scriptSnapshot, version2, textChangeRange, aggressiveChecks) {
|
|
167365
167365
|
if (textChangeRange) {
|
|
167366
|
-
if (
|
|
167366
|
+
if (version2 !== sourceFile.version) {
|
|
167367
167367
|
let newText;
|
|
167368
167368
|
const prefix = textChangeRange.span.start !== 0 ? sourceFile.text.substr(0, textChangeRange.span.start) : "";
|
|
167369
167369
|
const suffix = textSpanEnd(textChangeRange.span) !== sourceFile.text.length ? sourceFile.text.substr(textSpanEnd(textChangeRange.span)) : "";
|
|
@@ -167374,7 +167374,7 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
|
|
|
167374
167374
|
newText = prefix && suffix ? prefix + changedText + suffix : prefix ? prefix + changedText : changedText + suffix;
|
|
167375
167375
|
}
|
|
167376
167376
|
const newSourceFile = updateSourceFile(sourceFile, newText, textChangeRange, aggressiveChecks);
|
|
167377
|
-
setSourceFileFields(newSourceFile, scriptSnapshot,
|
|
167377
|
+
setSourceFileFields(newSourceFile, scriptSnapshot, version2);
|
|
167378
167378
|
newSourceFile.nameTable = void 0;
|
|
167379
167379
|
if (sourceFile !== newSourceFile && sourceFile.scriptSnapshot) {
|
|
167380
167380
|
if (sourceFile.scriptSnapshot.dispose) {
|
|
@@ -167395,7 +167395,7 @@ ${newComment.split("\n").map((c) => ` * ${c}`).join("\n")}
|
|
|
167395
167395
|
sourceFile.fileName,
|
|
167396
167396
|
scriptSnapshot,
|
|
167397
167397
|
options,
|
|
167398
|
-
|
|
167398
|
+
version2,
|
|
167399
167399
|
/*setNodeParents*/
|
|
167400
167400
|
true,
|
|
167401
167401
|
sourceFile.scriptKind
|
|
@@ -202330,7 +202330,7 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
202330
202330
|
usingSingleLineStringWriter: () => usingSingleLineStringWriter,
|
|
202331
202331
|
utf16EncodeAsString: () => utf16EncodeAsString,
|
|
202332
202332
|
validateLocaleAndSetLanguage: () => validateLocaleAndSetLanguage,
|
|
202333
|
-
version: () =>
|
|
202333
|
+
version: () => version,
|
|
202334
202334
|
versionMajorMinor: () => versionMajorMinor,
|
|
202335
202335
|
visitArray: () => visitArray,
|
|
202336
202336
|
visitCommaListElements: () => visitCommaListElements,
|
|
@@ -202355,7 +202355,7 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
202355
202355
|
var enableDeprecationWarnings = true;
|
|
202356
202356
|
var typeScriptVersion2;
|
|
202357
202357
|
function getTypeScriptVersion() {
|
|
202358
|
-
return typeScriptVersion2 ?? (typeScriptVersion2 = new Version(
|
|
202358
|
+
return typeScriptVersion2 ?? (typeScriptVersion2 = new Version(version));
|
|
202359
202359
|
}
|
|
202360
202360
|
function formatDeprecationMessage(name, error2, errorAfter, since, message) {
|
|
202361
202361
|
let deprecationMessage = error2 ? "DeprecationError: " : "DeprecationWarning: ";
|
|
@@ -202395,12 +202395,12 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
202395
202395
|
};
|
|
202396
202396
|
}
|
|
202397
202397
|
function createDeprecation(name, options = {}) {
|
|
202398
|
-
const
|
|
202398
|
+
const version2 = typeof options.typeScriptVersion === "string" ? new Version(options.typeScriptVersion) : options.typeScriptVersion ?? getTypeScriptVersion();
|
|
202399
202399
|
const errorAfter = typeof options.errorAfter === "string" ? new Version(options.errorAfter) : options.errorAfter;
|
|
202400
202400
|
const warnAfter = typeof options.warnAfter === "string" ? new Version(options.warnAfter) : options.warnAfter;
|
|
202401
202401
|
const since = typeof options.since === "string" ? new Version(options.since) : options.since ?? warnAfter;
|
|
202402
|
-
const error2 = options.error || errorAfter &&
|
|
202403
|
-
const warn = !warnAfter ||
|
|
202402
|
+
const error2 = options.error || errorAfter && version2.compareTo(errorAfter) >= 0;
|
|
202403
|
+
const warn = !warnAfter || version2.compareTo(warnAfter) >= 0;
|
|
202404
202404
|
return error2 ? createErrorDeprecation(name, errorAfter, since, options.message) : warn ? createWarningDeprecation(name, errorAfter, since, options.message) : noop;
|
|
202405
202405
|
}
|
|
202406
202406
|
function wrapFunction(deprecation, func) {
|
|
@@ -202795,11 +202795,11 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
202795
202795
|
this.log.writeLine(`Adding entry into typings cache: '${packageName}' => '${typingFile}'`);
|
|
202796
202796
|
}
|
|
202797
202797
|
const info = npmLock.packages && getProperty(npmLock.packages, `node_modules/${key}`) || getProperty(npmLock.dependencies, key);
|
|
202798
|
-
const
|
|
202799
|
-
if (!
|
|
202798
|
+
const version2 = info && info.version;
|
|
202799
|
+
if (!version2) {
|
|
202800
202800
|
continue;
|
|
202801
202801
|
}
|
|
202802
|
-
const newTyping = { typingLocation: typingFile, version: new Version(
|
|
202802
|
+
const newTyping = { typingLocation: typingFile, version: new Version(version2) };
|
|
202803
202803
|
this.packageNameToTypingLocation.set(packageName, newTyping);
|
|
202804
202804
|
}
|
|
202805
202805
|
}
|
|
@@ -202864,7 +202864,7 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
202864
202864
|
this.sendResponse({
|
|
202865
202865
|
kind: EventBeginInstallTypes,
|
|
202866
202866
|
eventId: requestId,
|
|
202867
|
-
typingsInstallerVersion:
|
|
202867
|
+
typingsInstallerVersion: version,
|
|
202868
202868
|
projectName: req.projectName
|
|
202869
202869
|
});
|
|
202870
202870
|
const scopedTypings = filteredTypings.map(typingsName);
|
|
@@ -202906,7 +202906,7 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
202906
202906
|
projectName: req.projectName,
|
|
202907
202907
|
packagesToInstall: scopedTypings,
|
|
202908
202908
|
installSuccess: ok,
|
|
202909
|
-
typingsInstallerVersion:
|
|
202909
|
+
typingsInstallerVersion: version
|
|
202910
202910
|
};
|
|
202911
202911
|
this.sendResponse(response);
|
|
202912
202912
|
}
|
|
@@ -207941,7 +207941,7 @@ ${options.prefix}` : "\n" : options.prefix
|
|
|
207941
207941
|
configFileName: configFileName(),
|
|
207942
207942
|
projectType: project instanceof ExternalProject ? "external" : "configured",
|
|
207943
207943
|
languageServiceEnabled: project.languageServiceEnabled,
|
|
207944
|
-
version
|
|
207944
|
+
version
|
|
207945
207945
|
};
|
|
207946
207946
|
this.eventHandler({ eventName: ProjectInfoTelemetryEvent, data });
|
|
207947
207947
|
function configFileName() {
|
|
@@ -210906,7 +210906,7 @@ ${json}${newLine}`;
|
|
|
210906
210906
|
"status"
|
|
210907
210907
|
/* Status */
|
|
210908
210908
|
]: () => {
|
|
210909
|
-
const response = { version
|
|
210909
|
+
const response = { version };
|
|
210910
210910
|
return this.requiredResponse(response);
|
|
210911
210911
|
},
|
|
210912
210912
|
[
|
|
@@ -214464,11 +214464,11 @@ Additional information: BADCLIENT: Bad error code, ${badCode} not found in range
|
|
|
214464
214464
|
this.minVersion = 0;
|
|
214465
214465
|
this.currentVersion = 0;
|
|
214466
214466
|
}
|
|
214467
|
-
versionToIndex(
|
|
214468
|
-
if (
|
|
214467
|
+
versionToIndex(version2) {
|
|
214468
|
+
if (version2 < this.minVersion || version2 > this.currentVersion) {
|
|
214469
214469
|
return void 0;
|
|
214470
214470
|
}
|
|
214471
|
-
return
|
|
214471
|
+
return version2 % _ScriptVersionCache2.maxVersions;
|
|
214472
214472
|
}
|
|
214473
214473
|
currentVersionToIndex() {
|
|
214474
214474
|
return this.currentVersion % _ScriptVersionCache2.maxVersions;
|
|
@@ -214553,8 +214553,8 @@ Additional information: BADCLIENT: Bad error code, ${badCode} not found in range
|
|
|
214553
214553
|
_ScriptVersionCache.maxVersions = 8;
|
|
214554
214554
|
var ScriptVersionCache = _ScriptVersionCache;
|
|
214555
214555
|
var LineIndexSnapshot = class _LineIndexSnapshot {
|
|
214556
|
-
constructor(
|
|
214557
|
-
this.version =
|
|
214556
|
+
constructor(version2, cache, index, changesSincePreviousVersion = emptyArray2) {
|
|
214557
|
+
this.version = version2;
|
|
214558
214558
|
this.cache = cache;
|
|
214559
214559
|
this.index = index;
|
|
214560
214560
|
this.changesSincePreviousVersion = changesSincePreviousVersion;
|
|
@@ -215879,11 +215879,11 @@ function datetimeRegex(args) {
|
|
|
215879
215879
|
regex2 = `${regex2}(${opts.join("|")})`;
|
|
215880
215880
|
return new RegExp(`^${regex2}$`);
|
|
215881
215881
|
}
|
|
215882
|
-
function isValidIP(ip,
|
|
215883
|
-
if ((
|
|
215882
|
+
function isValidIP(ip, version) {
|
|
215883
|
+
if ((version === "v4" || !version) && ipv4Regex.test(ip)) {
|
|
215884
215884
|
return true;
|
|
215885
215885
|
}
|
|
215886
|
-
if ((
|
|
215886
|
+
if ((version === "v6" || !version) && ipv6Regex.test(ip)) {
|
|
215887
215887
|
return true;
|
|
215888
215888
|
}
|
|
215889
215889
|
return false;
|
|
@@ -215910,11 +215910,11 @@ function isValidJWT(jwt, alg) {
|
|
|
215910
215910
|
return false;
|
|
215911
215911
|
}
|
|
215912
215912
|
}
|
|
215913
|
-
function isValidCidr(ip,
|
|
215914
|
-
if ((
|
|
215913
|
+
function isValidCidr(ip, version) {
|
|
215914
|
+
if ((version === "v4" || !version) && ipv4CidrRegex.test(ip)) {
|
|
215915
215915
|
return true;
|
|
215916
215916
|
}
|
|
215917
|
-
if ((
|
|
215917
|
+
if ((version === "v6" || !version) && ipv6CidrRegex.test(ip)) {
|
|
215918
215918
|
return true;
|
|
215919
215919
|
}
|
|
215920
215920
|
return false;
|
|
@@ -227599,9 +227599,6 @@ var {
|
|
|
227599
227599
|
Help
|
|
227600
227600
|
} = import_index.default;
|
|
227601
227601
|
|
|
227602
|
-
// src/index.ts
|
|
227603
|
-
var import_node_module = require("node:module");
|
|
227604
|
-
|
|
227605
227602
|
// src/commands/init.ts
|
|
227606
227603
|
var path9 = __toESM(require("node:path"));
|
|
227607
227604
|
|
|
@@ -227892,10 +227889,10 @@ function _supportsColor(haveStream, { streamIsTTY, sniffFlags = true } = {}) {
|
|
|
227892
227889
|
return 3;
|
|
227893
227890
|
}
|
|
227894
227891
|
if ("TERM_PROGRAM" in env) {
|
|
227895
|
-
const
|
|
227892
|
+
const version = Number.parseInt((env.TERM_PROGRAM_VERSION || "").split(".")[0], 10);
|
|
227896
227893
|
switch (env.TERM_PROGRAM) {
|
|
227897
227894
|
case "iTerm.app": {
|
|
227898
|
-
return
|
|
227895
|
+
return version >= 3 ? 3 : 2;
|
|
227899
227896
|
}
|
|
227900
227897
|
case "Apple_Terminal": {
|
|
227901
227898
|
return 2;
|
|
@@ -228619,7 +228616,7 @@ function eastAsianWidth(codePoint, { ambiguousAsWide = false } = {}) {
|
|
|
228619
228616
|
// ../../node_modules/.bun/string-width@7.2.0/node_modules/string-width/index.js
|
|
228620
228617
|
var import_emoji_regex = __toESM(require_emoji_regex(), 1);
|
|
228621
228618
|
var segmenter = new Intl.Segmenter();
|
|
228622
|
-
var defaultIgnorableCodePointRegex =
|
|
228619
|
+
var defaultIgnorableCodePointRegex = new RegExp("^\\p{Default_Ignorable_Code_Point}$", "u");
|
|
228623
228620
|
function stringWidth(string, options = {}) {
|
|
228624
228621
|
if (typeof string !== "string" || string.length === 0) {
|
|
228625
228622
|
return 0;
|
|
@@ -233515,11 +233512,8 @@ function registerVisualizeCommands(program3) {
|
|
|
233515
233512
|
}
|
|
233516
233513
|
|
|
233517
233514
|
// src/index.ts
|
|
233518
|
-
var import_meta = {};
|
|
233519
|
-
var require2 = (0, import_node_module.createRequire)(import_meta.url);
|
|
233520
|
-
var { version } = require2("../package.json");
|
|
233521
233515
|
var program2 = new Command();
|
|
233522
|
-
program2.name("mikk").description("The structural nervous system of your codebase").version(
|
|
233516
|
+
program2.name("mikk").description("The structural nervous system of your codebase").version("1.3.2");
|
|
233523
233517
|
registerInitCommand(program2);
|
|
233524
233518
|
registerAnalyzeCommand(program2);
|
|
233525
233519
|
registerDiffCommand(program2);
|