-
Notifications
You must be signed in to change notification settings - Fork 13
/
package.json
540 lines (540 loc) · 18 KB
/
package.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
{
"name": "languagetool-linter",
"displayName": "LanguageTool Linter",
"description": "LanguageTool integration for VS Code.",
"version": "0.24.2",
"engines": {
"vscode": "^1.90.0"
},
"categories": [
"Linters"
],
"keywords": [
"checker",
"grammar-checker",
"grammar",
"html",
"languagetool",
"markdown",
"mdx",
"proofread",
"spell",
"spelling"
],
"icon": "images/LanguageTool-Icon.png",
"galleryBanner": {
"color": "#6565f6",
"theme": "dark"
},
"author": "David L. Day <[email protected]> (https://www.davidlday.com)",
"publisher": "davidlday",
"license": "Apache-2.0",
"repository": {
"type": "git",
"url": "https://github.com/davidlday/vscode-languagetool-linter"
},
"bugs": {
"url": "https://github.com/davidlday/vscode-languagetool-linter/issues"
},
"homepage": "https://github.com/davidlday/vscode-languagetool-linter#readme",
"activationEvents": [
"onLanguage:plaintext",
"onLanguage:markdown",
"onLanguage:mdx",
"onLanguage:html"
],
"main": "./dist/extension.js",
"contributes": {
"commands": [
{
"command": "languagetoolLinter.checkDocument",
"title": "Check Document",
"category": "LanguageTool Linter"
},
{
"command": "languagetoolLinter.checkDocumentAsPlainText",
"title": "Force Check as Plain Text Document",
"category": "LanguageTool Linter"
},
{
"command": "languagetoolLinter.clearDocumentDiagnostics",
"title": "Clear Document Diagnostics",
"category": "LanguageTool Linter"
},
{
"command": "languagetoolLinter.smartFormatDocument",
"title": "Smart Format Document",
"category": "LanguageTool Linter"
},
{
"command": "languagetoolLinter.toggleSuspendLinting",
"title": "Toggle LanguageTool Linting on/off (temporarily). Linting on demand remains available.",
"category": "LanguageTool Linter"
}
],
"menus": {
"commandPalette": [
{
"command": "languagetoolLinter.checkDocument",
"when": "editorLangId == markdown || editorLangId == html"
},
{
"command": "languagetoolLinter.checkDocumentAsPlainText",
"when": "editorLangId != markdown && editorLangId != html"
},
{
"command": "languagetoolLinter.clearDocumentDiagnostics"
},
{
"command": "languagetoolLinter.smartFormatDocument",
"when": "editorLangId == markdown || editorLangId == html"
}
],
"editor/context": [
{
"command": "languagetoolLinter.checkDocument",
"title": "LanguageTool: Check Document",
"when": "editorLangId == markdown || editorLangId == html",
"group": "LanguageTool"
},
{
"command": "languagetoolLinter.checkDocumentAsPlainText",
"title": "LanguageTool: Force Check as Plain Text Document",
"when": "editorLangId != markdown && editorLangId != html",
"group": "LanguageTool"
},
{
"command": "languagetoolLinter.clearDocumentDiagnostics",
"title": "LanguageTool: Clear Document Diagnotics",
"group": "LanguageTool"
},
{
"command": "languagetoolLinter.smartFormatDocument",
"title": "LanguageTool: Smart Format Document",
"when": "editorLangId == markdown || editorLangId == html",
"group": "LanguageTool"
}
]
},
"configuration": {
"type": "object",
"title": "LanguageTool Linter",
"properties": {
"languageToolLinter.smartFormat.onType": {
"type": "boolean",
"default": false,
"description": "Run smart format as you type for quotes (\u201c\u201d\u2018\u2019), em-dashes and en-dashes, and ellipses (\u2026). Ensure 'Editor: Format On Type' is enabled."
},
"languageToolLinter.smartFormat.onSave": {
"type": "boolean",
"default": false,
"description": "Run smart format when you save for quotes (\u201c\u201d\u2018\u2019), em-dashes and en-dashes, and ellipses (\u2026)."
},
"languageToolLinter.diagnosticSeverity": {
"type": "string",
"default": "warning",
"description": "Set the severity level for LanguageTool diagnostics.",
"enum": [
"information",
"warning",
"error"
]
},
"languageToolLinter.diagnosticSeverityAuto": {
"type": "boolean",
"default": false,
"description": "Spelling mistakes will be set as Error, while punctuation, grammar and typography mistakes as Warning. Anything else as the configured Diagnostic Severity level (recommended to be set as Information when using this option)."
},
"languageToolLinter.hideDiagnosticsOnChange": {
"type": "boolean",
"default": false,
"description": "Hide diagnostic messages on document changes. Most noticable when used with 'Lint on Change'."
},
"languageToolLinter.hideRuleIds": {
"type": "boolean",
"default": false,
"description": "Hide Rule IDs in messages."
},
"languageToolLinter.lintOnChange": {
"type": "boolean",
"default": false,
"description": "Lint every time the document changes. Use with caution."
},
"languageToolLinter.lintOnSave": {
"type": "boolean",
"default": true,
"description": "Lint documents when they're saved."
},
"languageToolLinter.lintOnOpen": {
"type": "boolean",
"default": false,
"description": "Lint documents when they're opened."
},
"languageToolLinter.serviceType": {
"type": "string",
"default": "external",
"description": "What kind of LanguageTool service to use: external (default), public, or managed.",
"enum": [
"external",
"managed",
"public"
],
"enumDescriptions": [
"Provide a URL to an external LanguageTool service. Defaults to 'http://localhost:8081'. Specify the URL in 'External: Url'.",
"Let LanguageTool Linter manage a local service. Specify the classpath or LanguageTool jar file in 'Managed: Class Path'.",
"Use the public LanguageTool API Service at https://languagetool.org/api."
]
},
"languageToolLinter.external.url": {
"type": "string",
"default": "http://localhost:8081",
"description": "URL of your LanguageTool server. Defaults to localhost on port 8081."
},
"languageToolLinter.external.username": {
"type": "string",
"default": "",
"description": "Set to get Premium API access if you use the languagetool.org api instance: your username/email as used to log in at languagetool.org."
},
"languageToolLinter.external.apiKey": {
"type": "string",
"default": "",
"description": "Set to get Premium API access if you use the languagetool.org api instance: your API key."
},
"languageToolLinter.managed.classPath": {
"type": "string",
"default": "",
"markdownDescription": "Custom classpath for managed server. Separate multiple paths using the native filesystem separator. Supports file globbing via [node-glob](https://github.com/isaacs/node-glob)."
},
"languageToolLinter.managed.jarFile": {
"type": "string",
"default": "",
"description": "DEPRECATED. Path to languagetool-server.jar on your local machine."
},
"languageToolLinter.managed.portMinimum": {
"type": "number",
"minimum": 1024,
"maximum": 65535,
"default": 9500,
"description": "Minimum port number to use for managed service."
},
"languageToolLinter.managed.portMaximum": {
"type": "number",
"minimum": 1024,
"maximum": 65535,
"default": 65535,
"description": "Minimum port number to use for managed service."
},
"languageToolLinter.languageTool.language": {
"type": "string",
"default": "auto",
"description": "A language code like en-US, de-DE, fr, or auto to guess the language automatically (see preferredVariants below). For languages with variants (English, German, Portuguese) spell checking will only be activated when you specify the variant, e.g. en-GB instead of just en.",
"enum": [
"auto",
"ast-ES",
"be-BY",
"br-FR",
"ca-ES",
"ca-ES-valencia",
"zh-CN",
"da-DK",
"nl",
"en",
"en-AU",
"en-CA",
"en-GB",
"en-NZ",
"en-ZA",
"en-US",
"eo",
"fr",
"gl-ES",
"de",
"de-AT",
"de-DE",
"de-CH",
"el-GR",
"it",
"ja-JP",
"km-KH",
"fa",
"pl-PL",
"pt",
"pt-AO",
"pt-BR",
"pt-MZ",
"pt-PT",
"ro-RO",
"ru-RU",
"de-DE-x-simple-language",
"sk-SK",
"sl-SI",
"es",
"sv",
"tl-PH",
"ta-IN",
"uk-UA"
],
"enumDescriptions": [
"Auto Select",
"Asturian",
"Belarusian",
"Breton",
"Catalan",
"Catalan (Valencian)",
"Chinese",
"Danish",
"Dutch",
"English",
"English (Australian)",
"English (Canadian)",
"English (GB)",
"English (New Zealand)",
"English (South African)",
"English (US)",
"Esperanto",
"French",
"Galician",
"German",
"German (Austria)",
"German (Germany)",
"German (Swiss)",
"Greek",
"Italian",
"Japanese",
"Khmer",
"Persian",
"Polish",
"Portuguese",
"Portuguese (Angola preAO)",
"Portuguese (Brazil)",
"Portuguese (Mo\u00e7ambique preAO)",
"Portuguese (Portugal)",
"Romanian",
"Russian",
"Simple German",
"Slovak",
"Slovenian",
"Spanish",
"Swedish",
"Tagalog",
"Tamil",
"Ukrainian"
]
},
"languageToolLinter.languageTool.motherTongue": {
"type": "string",
"default": "",
"description": "A language code of the user's native language, enabling false friends checks for some language pairs.",
"enum": [
"",
"ast-ES",
"be-BY",
"br-FR",
"ca-ES",
"ca-ES-valencia",
"zh-CN",
"da-DK",
"nl",
"en",
"en-AU",
"en-CA",
"en-GB",
"en-NZ",
"en-ZA",
"en-US",
"eo",
"fr",
"gl-ES",
"de",
"de-AT",
"de-DE",
"de-CH",
"el-GR",
"it",
"ja-JP",
"km-KH",
"fa",
"pl-PL",
"pt",
"pt-AO",
"pt-BR",
"pt-MZ",
"pt-PT",
"ro-RO",
"ru-RU",
"de-DE-x-simple-language",
"sk-SK",
"sl-SI",
"es",
"sv",
"tl-PH",
"ta-IN",
"uk-UA"
],
"enumDescriptions": [
"No Language Selected",
"Asturian",
"Belarusian",
"Breton",
"Catalan",
"Catalan (Valencian)",
"Chinese",
"Danish",
"Dutch",
"English",
"English (Australian)",
"English (Canadian)",
"English (GB)",
"English (New Zealand)",
"English (South African)",
"English (US)",
"Esperanto",
"French",
"Galician",
"German",
"German (Austria)",
"German (Germany)",
"German (Swiss)",
"Greek",
"Italian",
"Japanese",
"Khmer",
"Persian",
"Polish",
"Portuguese",
"Portuguese (Angola preAO)",
"Portuguese (Brazil)",
"Portuguese (Mo\u00e7ambique preAO)",
"Portuguese (Portugal)",
"Romanian",
"Russian",
"Simple German",
"Slovak",
"Slovenian",
"Spanish",
"Swedish",
"Tagalog",
"Tamil",
"Ukrainian"
]
},
"languageToolLinter.languageTool.preferredVariants": {
"type": "string",
"default": "",
"description": "Comma-separated list of preferred language variants. The language detector used with language=auto can detect e.g. English, but it cannot decide whether British English or American English is used. Thus this parameter can be used to specify the preferred variants like en-GB and de-AT. Only available with language=auto."
},
"languageToolLinter.languageTool.disabledRules": {
"type": "string",
"default": "",
"description": "IDs of rules to be disabled, comma-separated, no spaces. These IDs are passed directly to the LanguageTool service and will not be returned with diagnostics."
},
"languageToolLinter.languageTool.disabledCategories": {
"type": "string",
"default": "",
"description": "IDs of categories to be disabled, comma-separated, no spaces. These IDs are passed directly to the LanguageTool service and will not be returned with diagnostics."
},
"languageToolLinter.languageTool.level": {
"type": "string",
"default": "",
"description": "If set to picky, additional rules will be activated, i.e. rules that you might only find useful when checking formal text.",
"enum": [
"",
"default",
"picky"
],
"enumDescriptions": [
"",
"Standard Mode",
"Picky Mode"
]
},
"languageToolLinter.languageTool.ignoredWordsGlobal": {
"type": "array",
"items": {
"type": "string"
},
"scope": "application",
"default": [],
"description": "Global list of words to ignore in spellcheck."
},
"languageToolLinter.languageTool.ignoredWordsInWorkspace": {
"type": "array",
"items": {
"type": "string"
},
"scope": "window",
"default": [],
"description": "Workspace list of words to ignore in spellcheck. This setting is ignored at the User (Global) level."
},
"languageToolLinter.languageTool.ignoredWordHint": {
"type": "boolean",
"default": true,
"description": "Shows a hint for ignored words, providing a Quick Fix to remove the word from the ignored list."
},
"languageToolLinter.plainText.enabled": {
"type": "boolean",
"default": true,
"description": "Enable linting of documents as plain text. The entire document is sent to LanguageTool as-is. Use Plain Text > Language IDs to determine which documents are considered Plain Text."
},
"languageToolLinter.plainText.languageIds": {
"type": "array",
"items": {
"type": "string"
},
"default": [
"plaintext"
],
"markdownDescription": "A list of [Language IDs](https://code.visualstudio.com/docs/languages/identifiers#_known-language-identifiers) to treat as plain text."
}
}
}
},
"scripts": {
"clean": "rm -rf out/* dist/*",
"vscode:prepublish": "webpack --mode production",
"webpack": "webpack --mode development",
"webpack-dev": "webpack --mode development --watch --info-verbosity verbose",
"compile": "webpack --mode none",
"watch": "webpack --mode development --watch --info-verbosity verbose",
"test-compile": "npm run main-out && tsc -p ./",
"main-out": "json -I -f package.json -e 'this.main=\"./out/src/extension.js\"'",
"main-dist": "json -I -f package.json -e 'this.main=\"./dist/extension.js\"'",
"pretest": "npm run test-compile",
"test": "node ./out/test/runTest.js && npm run main-dist",
"lint": "eslint ./src/"
},
"devDependencies": {
"@eslint/js": "^9.11.1",
"@types/eslint__js": "^8.42.3",
"@types/glob": "^8.1.0",
"@types/mocha": "^10.0.8",
"@types/node": "^22.9.1",
"@types/node-fetch": "^2.6.11",
"@types/vscode": "^1.90.0",
"@types/webpack": "^5.28.5",
"@typescript-eslint/eslint-plugin": "^8.15.0",
"@typescript-eslint/parser": "^8.15.0",
"@vscode/test-electron": "^2.4.1",
"@vscode/vsce": "^3.0.0",
"eslint": "^9.15.0",
"eslint-config-prettier": "^9.1.0",
"eslint-plugin-jsdoc": "^50.3.1",
"json": "^11.0.0",
"mocha": "^10.7.3",
"ts-loader": "^9.5.1",
"ts-node": "^10.9.2",
"typescript": "^5.5.4",
"typescript-eslint": "^8.15.0",
"webpack": "^5.95.0",
"webpack-cli": "^5.1.4",
"webpack-license-plugin": "^4.5.0"
},
"dependencies": {
"annotatedtext-rehype": "^0.6.0",
"annotatedtext-remark": "^0.8.0",
"execa": "^5.0.0",
"glob": "^11.0.0",
"node-fetch": "^2.7.0",
"portfinder": "^1.0.32"
}
}