vscode: tweak spell-checking configuration
it doesn't seem possible to override the includeRegExpList for specific languages/file types if there's a global match, so list the common languages explicitly to limit spell-checking in comments/strings there. Other filetypes are using the built-in (or user-configured) defaults. Add a second section for git-commit files as an example of how to extend the configuration for other file-types. Change-Id: I3c8039ba3b6b5951ce29a9f290e35b6a9bbdb4ff Reviewed-on: https://gerrit.libreoffice.org/c/core/+/187066 Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com> Tested-by: Jenkins
This commit is contained in:
+10
-3
@@ -141,9 +141,9 @@
|
|||||||
"cSpell.noSuggestDictionaries": ["ignoreWords"],
|
"cSpell.noSuggestDictionaries": ["ignoreWords"],
|
||||||
"cSpell.languageSettings": [
|
"cSpell.languageSettings": [
|
||||||
{
|
{
|
||||||
// check all file types, but only in comments and strings (what the regexes consider
|
// limit spellchecking to comments and strings (what the regexes consider
|
||||||
// a comment/string)
|
// a comment/string) for these languages/file-types
|
||||||
"languageId": "*",
|
"languageId": "c,objective-c,cpp,objective-cpp,makefile,m4,perl,python,automake",
|
||||||
// turn off compound words, because it is only checking strings.
|
// turn off compound words, because it is only checking strings.
|
||||||
"allowCompoundWords": false,
|
"allowCompoundWords": false,
|
||||||
// Only check comments and strings
|
// Only check comments and strings
|
||||||
@@ -155,6 +155,13 @@
|
|||||||
"ignoreRegExpList": [
|
"ignoreRegExpList": [
|
||||||
"/#include.*/"
|
"/#include.*/"
|
||||||
]
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"languageId": "git-commit",
|
||||||
|
"allowCompoundWords": true,
|
||||||
|
"ignoreRegExpList": [
|
||||||
|
"/Change-Id:.*/"
|
||||||
|
]
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
// hide from "Problems" tab, however also makes it less visible in the editor, but there are
|
// hide from "Problems" tab, however also makes it less visible in the editor, but there are
|
||||||
|
|||||||
Reference in New Issue
Block a user