cspell 5.18.0 → 5.18.1
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.
|
@@ -6,7 +6,7 @@ const util_1 = require("../util/util");
|
|
|
6
6
|
function emitSuggestionResult(result, options) {
|
|
7
7
|
const { word, suggestions } = result;
|
|
8
8
|
const { verbose, output = console } = options;
|
|
9
|
-
output.log(word ? chalk.
|
|
9
|
+
output.log(word ? chalk.yellow(word) : chalk.yellow('<empty>') + ':');
|
|
10
10
|
if (!suggestions.length) {
|
|
11
11
|
console.log(chalk.yellow(' <no suggestions>'));
|
|
12
12
|
return;
|
|
@@ -14,13 +14,14 @@ function emitSuggestionResult(result, options) {
|
|
|
14
14
|
if (verbose) {
|
|
15
15
|
const maxWidth = suggestions.map((r) => r.word.length).reduce((max, len) => Math.max(max, len), 0);
|
|
16
16
|
for (const sug of suggestions) {
|
|
17
|
-
const { word, cost, dictionaries } = sug;
|
|
18
|
-
const
|
|
17
|
+
const { word, cost, dictionaries, compoundWord } = sug;
|
|
18
|
+
const w = compoundWord || word;
|
|
19
|
+
const padding = ' '.repeat(maxWidth - w.length);
|
|
19
20
|
const forbid = sug.forbidden ? chalk.red('X') : ' ';
|
|
20
21
|
const ignore = sug.noSuggest ? chalk.yellow('N') : ' ';
|
|
21
22
|
const strCost = (0, util_1.padLeft)(cost.toString(10), 4);
|
|
22
23
|
const dicts = dictionaries.map((n) => chalk.gray(n)).join(', ');
|
|
23
|
-
output.log(` - ${formatWord(
|
|
24
|
+
output.log(` - ${formatWord(w, sug)}${padding} ${forbid}${ignore} - ${chalk.yellow(strCost)} ${dicts}`);
|
|
24
25
|
}
|
|
25
26
|
}
|
|
26
27
|
else {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "cspell",
|
|
3
|
-
"version": "5.18.
|
|
3
|
+
"version": "5.18.1",
|
|
4
4
|
"description": "A Spelling Checker for Code!",
|
|
5
5
|
"funding": "https://github.com/streetsidesoftware/cspell?sponsor=1",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -70,13 +70,13 @@
|
|
|
70
70
|
},
|
|
71
71
|
"homepage": "https://streetsidesoftware.github.io/cspell/",
|
|
72
72
|
"dependencies": {
|
|
73
|
-
"@cspell/cspell-pipe": "^5.18.
|
|
73
|
+
"@cspell/cspell-pipe": "^5.18.1",
|
|
74
74
|
"chalk": "^4.1.2",
|
|
75
|
-
"commander": "^
|
|
75
|
+
"commander": "^9.0.0",
|
|
76
76
|
"comment-json": "^4.1.1",
|
|
77
|
-
"cspell-gitignore": "^5.18.
|
|
78
|
-
"cspell-glob": "^5.18.
|
|
79
|
-
"cspell-lib": "^5.18.
|
|
77
|
+
"cspell-gitignore": "^5.18.1",
|
|
78
|
+
"cspell-glob": "^5.18.1",
|
|
79
|
+
"cspell-lib": "^5.18.1",
|
|
80
80
|
"fast-json-stable-stringify": "^2.1.0",
|
|
81
81
|
"file-entry-cache": "^6.0.1",
|
|
82
82
|
"fs-extra": "^10.0.0",
|
|
@@ -91,8 +91,8 @@
|
|
|
91
91
|
"node": ">=12.13.0"
|
|
92
92
|
},
|
|
93
93
|
"devDependencies": {
|
|
94
|
-
"@cspell/cspell-json-reporter": "^5.18.
|
|
95
|
-
"@cspell/cspell-types": "^5.18.
|
|
94
|
+
"@cspell/cspell-json-reporter": "^5.18.1",
|
|
95
|
+
"@cspell/cspell-types": "^5.18.1",
|
|
96
96
|
"@types/file-entry-cache": "^5.0.2",
|
|
97
97
|
"@types/fs-extra": "^9.0.13",
|
|
98
98
|
"@types/glob": "^7.2.0",
|
|
@@ -107,5 +107,5 @@
|
|
|
107
107
|
"rollup": "^2.66.1",
|
|
108
108
|
"rollup-plugin-dts": "^4.1.0"
|
|
109
109
|
},
|
|
110
|
-
"gitHead": "
|
|
110
|
+
"gitHead": "8b94979b57a7b1a11f8efbd5bc086d29d496f7be"
|
|
111
111
|
}
|