cspell 10.3.4-alpha.0 → 10.3.5
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/esm/app.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { C as ApplicationError, S as width, T as console, _ as padLeft, a as parseApplicationFeatureFlags, b as pruneAnsiTextEnd, c as listDictionaries, d as validateUnitSize, f as unindent, g as tableToLines, i as lint, l as ReportChoicesAll, m as npmPackage, n as checkText, o as suggestions, p as DEFAULT_CACHE_LOCATION, r as createInit, s as trace, t as IncludeExcludeFlag, u as cvtLinterCliCommandOptionsToLinterCliOptions, v as padWidth, w as CheckFailed, x as pruneAnsiTextStart, y as ansiWidth } from "./application-
|
|
1
|
+
import { C as ApplicationError, S as width, T as console, _ as padLeft, a as parseApplicationFeatureFlags, b as pruneAnsiTextEnd, c as listDictionaries, d as validateUnitSize, f as unindent, g as tableToLines, i as lint, l as ReportChoicesAll, m as npmPackage, n as checkText, o as suggestions, p as DEFAULT_CACHE_LOCATION, r as createInit, s as trace, t as IncludeExcludeFlag, u as cvtLinterCliCommandOptionsToLinterCliOptions, v as padWidth, w as CheckFailed, x as pruneAnsiTextStart, y as ansiWidth } from "./application-CdcDwTFc.js";
|
|
2
2
|
import { Link } from "cspell-lib";
|
|
3
3
|
import chalk from "chalk";
|
|
4
4
|
import * as iPath from "node:path";
|
|
@@ -402,6 +402,7 @@ async function action(fileGlobs, cliOptions) {
|
|
|
402
402
|
const { mustFindFiles, fileList, files, file, forceCheck } = options;
|
|
403
403
|
if (forceCheck && !file?.length && !files?.length && !fileList?.length) this.error("error: --force-check requires --file, --files, or --file-list to be specified");
|
|
404
404
|
if (fileGlobs.length && (file?.length || files?.length)) this.error("error: mixing globs and --file is not supported");
|
|
405
|
+
if (fileGlobs.length && forceCheck) this.error("error: mixing globs and --force-check is not supported");
|
|
405
406
|
const result = await lint(fileGlobs, options);
|
|
406
407
|
if (!fileGlobs.length && !result.files && !result.errors && !fileList && !files?.length && !file?.length) {
|
|
407
408
|
this.outputHelp();
|
|
@@ -1213,7 +1213,7 @@ try {
|
|
|
1213
1213
|
const pkgDir = _dirname;
|
|
1214
1214
|
const npmPackage = {
|
|
1215
1215
|
name: "cspell",
|
|
1216
|
-
version: "10.3.
|
|
1216
|
+
version: "10.3.5",
|
|
1217
1217
|
engines: { node: ">=22.18.0" }
|
|
1218
1218
|
};
|
|
1219
1219
|
//#endregion
|
|
@@ -2513,16 +2513,17 @@ async function processFile(file, cache, prefetch, processFileOptions) {
|
|
|
2513
2513
|
result.fileInfo = fileInfo;
|
|
2514
2514
|
let spellResult = {};
|
|
2515
2515
|
try {
|
|
2516
|
-
const { showSuggestions: generateSuggestions, validateDirectives, skipValidation, forceCheck
|
|
2516
|
+
const { showSuggestions: generateSuggestions, validateDirectives, skipValidation, forceCheck } = cfg.options;
|
|
2517
2517
|
const validateOptions = clean({
|
|
2518
2518
|
generateSuggestions,
|
|
2519
2519
|
numSuggestions: configInfo.config.numSuggestions ?? 5,
|
|
2520
2520
|
validateDirectives,
|
|
2521
2521
|
skipValidation,
|
|
2522
|
-
|
|
2522
|
+
forceCheck
|
|
2523
2523
|
});
|
|
2524
2524
|
const r = await spellCheckDocument(doc, validateOptions, userSettings);
|
|
2525
2525
|
spellResult = r;
|
|
2526
|
+
if (r.errors?.length) throw r.errors[0];
|
|
2526
2527
|
result.processed = r.checked;
|
|
2527
2528
|
result.perf = r.perf ? { ...r.perf } : void 0;
|
|
2528
2529
|
result.issues = Text.calculateTextDocumentOffsets(doc.uri, text, r.issues).map(mapIssue);
|
|
@@ -2692,7 +2693,7 @@ function prefetch(fileToProcess, cfg) {
|
|
|
2692
2693
|
elapsedTimeMs: getElapsedTimeMs()
|
|
2693
2694
|
} };
|
|
2694
2695
|
const uri = filenameToUri(filename, cfg.root).href;
|
|
2695
|
-
const checkResult = await shouldCheckDocument({ uri }, {}, cfg.config);
|
|
2696
|
+
const checkResult = await shouldCheckDocument({ uri }, { forceCheck: cfg.forceCheck }, cfg.config);
|
|
2696
2697
|
if (!checkResult.shouldCheck) return {
|
|
2697
2698
|
skip: true,
|
|
2698
2699
|
skipReason: checkResult.reason || "Ignored by configuration."
|
|
@@ -2723,6 +2724,7 @@ async function processFiles(files, options) {
|
|
|
2723
2724
|
const prefetchConfig = {
|
|
2724
2725
|
root: options.cfg.root,
|
|
2725
2726
|
maxFileSize: options.cfg.maxFileSize,
|
|
2727
|
+
forceCheck: !!options.cfg.options.forceCheck,
|
|
2726
2728
|
config: options.configInfo.config,
|
|
2727
2729
|
cache
|
|
2728
2730
|
};
|
|
@@ -3062,7 +3064,7 @@ async function determineFilesToCheck(configInfo, cfg, reporter, globInfo) {
|
|
|
3062
3064
|
};
|
|
3063
3065
|
const enableGlobDot = cfg.enableGlobDot ?? configInfo.config.enableGlobDot;
|
|
3064
3066
|
if (enableGlobDot !== void 0) globOptions.dot = enableGlobDot;
|
|
3065
|
-
const includeFilterCountSkipped = countFiles(createIncludeFileFilterFn(allGlobs, root, enableGlobDot));
|
|
3067
|
+
const includeFilterCountSkipped = countFiles(cfg.options.forceCheck && !cfg.fileGlobs.length ? () => true : createIncludeFileFilterFn(allGlobs, root, enableGlobDot));
|
|
3066
3068
|
const rawCliFiles = cfg.files?.map((file) => resolveFilename(file, root)).filter(includeFilterCountSkipped);
|
|
3067
3069
|
const cliFiles = cfg.options.mustFindFiles ? rawCliFiles : rawCliFiles && pipeAsync(rawCliFiles, opFilterAsync(isFile));
|
|
3068
3070
|
const foundFiles = hasFileLists ? concatAsyncIterables(cliFiles, await useFileLists(fileLists, includeFilterCountSkipped)) : cliFiles || [];
|
|
@@ -3532,4 +3534,4 @@ function parseApplicationFeatureFlags(flags) {
|
|
|
3532
3534
|
//#endregion
|
|
3533
3535
|
export { ApplicationError as C, width as S, console as T, padLeft as _, parseApplicationFeatureFlags as a, pruneAnsiTextEnd as b, listDictionaries as c, validateUnitSize as d, unindent as f, tableToLines as g, getReporter as h, lint as i, ReportChoicesAll as l, npmPackage as m, checkText as n, suggestions as o, DEFAULT_CACHE_LOCATION as p, createInit as r, trace as s, IncludeExcludeFlag as t, cvtLinterCliCommandOptionsToLinterCliOptions as u, padWidth as v, CheckFailed as w, pruneAnsiTextStart as x, ansiWidth as y };
|
|
3534
3536
|
|
|
3535
|
-
//# sourceMappingURL=application-
|
|
3537
|
+
//# sourceMappingURL=application-CdcDwTFc.js.map
|
package/dist/esm/application.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as parseApplicationFeatureFlags, c as listDictionaries, i as lint, n as checkText, o as suggestions, r as createInit, s as trace, t as IncludeExcludeFlag } from "./application-
|
|
1
|
+
import { a as parseApplicationFeatureFlags, c as listDictionaries, i as lint, n as checkText, o as suggestions, r as createInit, s as trace, t as IncludeExcludeFlag } from "./application-CdcDwTFc.js";
|
|
2
2
|
export { IncludeExcludeFlag, checkText, createInit, lint, listDictionaries, parseApplicationFeatureFlags, suggestions, trace };
|
package/dist/esm/index.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { a as parseApplicationFeatureFlags, c as listDictionaries, h as getReporter, i as lint, n as checkText, o as suggestions, r as createInit, s as trace, t as IncludeExcludeFlag } from "./application-
|
|
1
|
+
import { a as parseApplicationFeatureFlags, c as listDictionaries, h as getReporter, i as lint, n as checkText, o as suggestions, r as createInit, s as trace, t as IncludeExcludeFlag } from "./application-CdcDwTFc.js";
|
|
2
2
|
export * from "@cspell/cspell-types";
|
|
3
3
|
export { IncludeExcludeFlag, checkText, createInit, getReporter as getDefaultReporter, lint, listDictionaries, parseApplicationFeatureFlags, suggestions, trace };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "cspell",
|
|
3
|
-
"version": "10.3.
|
|
3
|
+
"version": "10.3.5",
|
|
4
4
|
"description": "A Spelling Checker for Code!",
|
|
5
5
|
"funding": "https://github.com/streetsidesoftware/cspell?sponsor=1",
|
|
6
6
|
"bin": {
|
|
@@ -90,23 +90,23 @@
|
|
|
90
90
|
},
|
|
91
91
|
"homepage": "https://cspell.org/",
|
|
92
92
|
"dependencies": {
|
|
93
|
-
"@cspell/cspell-json-reporter": "10.3.
|
|
94
|
-
"@cspell/cspell-performance-monitor": "10.3.
|
|
95
|
-
"@cspell/cspell-pipe": "10.3.
|
|
96
|
-
"@cspell/cspell-types": "10.3.
|
|
97
|
-
"@cspell/cspell-worker": "10.3.
|
|
98
|
-
"@cspell/dynamic-import": "10.3.
|
|
99
|
-
"@cspell/url": "10.3.
|
|
93
|
+
"@cspell/cspell-json-reporter": "10.3.5",
|
|
94
|
+
"@cspell/cspell-performance-monitor": "10.3.5",
|
|
95
|
+
"@cspell/cspell-pipe": "10.3.5",
|
|
96
|
+
"@cspell/cspell-types": "10.3.5",
|
|
97
|
+
"@cspell/cspell-worker": "10.3.5",
|
|
98
|
+
"@cspell/dynamic-import": "10.3.5",
|
|
99
|
+
"@cspell/url": "10.3.5",
|
|
100
100
|
"ansi-regex": "^6.3.0",
|
|
101
101
|
"chalk": "^6.0.0",
|
|
102
102
|
"chalk-template": "^1.1.2",
|
|
103
103
|
"commander": "^15.0.0",
|
|
104
|
-
"cspell-config-lib": "10.3.
|
|
105
|
-
"cspell-dictionary": "10.3.
|
|
106
|
-
"cspell-gitignore": "10.3.
|
|
107
|
-
"cspell-glob": "10.3.
|
|
108
|
-
"cspell-io": "10.3.
|
|
109
|
-
"cspell-lib": "10.3.
|
|
104
|
+
"cspell-config-lib": "10.3.5",
|
|
105
|
+
"cspell-dictionary": "10.3.5",
|
|
106
|
+
"cspell-gitignore": "10.3.5",
|
|
107
|
+
"cspell-glob": "10.3.5",
|
|
108
|
+
"cspell-io": "10.3.5",
|
|
109
|
+
"cspell-lib": "10.3.5",
|
|
110
110
|
"flatted": "^3.4.4",
|
|
111
111
|
"semver": "^7.8.5",
|
|
112
112
|
"tinyglobby": "^0.2.17"
|
|
@@ -120,5 +120,5 @@
|
|
|
120
120
|
"micromatch": "^4.0.8",
|
|
121
121
|
"minimatch": "^9.0.9"
|
|
122
122
|
},
|
|
123
|
-
"gitHead": "
|
|
123
|
+
"gitHead": "f37a244a54b686fc1ac11272d6019b9a059b062a"
|
|
124
124
|
}
|