From dbbabedec6decfffe9aba62e58320cff530cbfb4 Mon Sep 17 00:00:00 2001 From: Tillmann Rendel Date: Tue, 1 Feb 2022 14:55:29 +0100 Subject: [PATCH 1/5] Allow comments in VS Code configuration Since JSON formally cannot contain comments, GitHub highlights comments in JSON files as errors, but the configuration files for VS Code in this repository contain comments. This commit configures GitHub to use a different syntax highlighter for the affected files. --- .vscode/.gitattributes | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 .vscode/.gitattributes diff --git a/.vscode/.gitattributes b/.vscode/.gitattributes new file mode 100644 index 000000000..026e40131 --- /dev/null +++ b/.vscode/.gitattributes @@ -0,0 +1,2 @@ +# Configure GitHub to not mark comments in configuration files as errors +*.json linguist-language=JSON-with-Comments From 420045210c8d7ea316ebf8de236a81388f0e3698 Mon Sep 17 00:00:00 2001 From: Tillmann Rendel Date: Tue, 1 Feb 2022 15:27:59 +0100 Subject: [PATCH 2/5] Try moving .gitattributes to root --- .vscode/.gitattributes => .gitattributes | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) rename .vscode/.gitattributes => .gitattributes (58%) diff --git a/.vscode/.gitattributes b/.gitattributes similarity index 58% rename from .vscode/.gitattributes rename to .gitattributes index 026e40131..73153b0d3 100644 --- a/.vscode/.gitattributes +++ b/.gitattributes @@ -1,2 +1,2 @@ # Configure GitHub to not mark comments in configuration files as errors -*.json linguist-language=JSON-with-Comments +.vscode/*.json linguist-language=JSON-with-Comments From 587e6d2dede880fda71fcb84de53e54e6eb897dc Mon Sep 17 00:00:00 2001 From: Tillmann Rendel Date: Tue, 1 Feb 2022 23:33:24 +0100 Subject: [PATCH 3/5] Move back to .vscode folder --- .gitattributes => .vscode/.gitattributes | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) rename .gitattributes => .vscode/.gitattributes (58%) diff --git a/.gitattributes b/.vscode/.gitattributes similarity index 58% rename from .gitattributes rename to .vscode/.gitattributes index 73153b0d3..c050fbbf3 100644 --- a/.gitattributes +++ b/.vscode/.gitattributes @@ -1,2 +1,2 @@ # Configure GitHub to not mark comments in configuration files as errors -.vscode/*.json linguist-language=JSON-with-Comments +*.json linguist-language=jsonc From d26f6f0f2f7bdac8468778d2de938767de699b59 Mon Sep 17 00:00:00 2001 From: Tillmann Rendel Date: Tue, 1 Feb 2022 23:36:50 +0100 Subject: [PATCH 4/5] Format cspell config and tweak comments Mostly to flush the highlighting cache on GitHub, but hopefully it also improves the file. --- .vscode/cSpell.json | 26 ++++++++++++++++++++------ 1 file changed, 20 insertions(+), 6 deletions(-) diff --git a/.vscode/cSpell.json b/.vscode/cSpell.json index 95b6f0485..2ff4d4b7e 100644 --- a/.vscode/cSpell.json +++ b/.vscode/cSpell.json @@ -1,7 +1,12 @@ // `cspell` settings { - "version": "0.1", // Version of the setting file. Always 0.1 - "language": "en", // language - current active spelling language + // version of the setting file (always 0.1) + "version": "0.1", + + // spelling language + "language": "en", + + // custom dictionaries "dictionaries": ["acronyms+names", "jargon", "people", "shell", "workspace"], "dictionaryDefinitions": [ { "name": "acronyms+names", "path": "./cspell.dictionaries/acronyms+names.wordlist.txt" }, @@ -10,10 +15,19 @@ { "name": "shell", "path": "./cspell.dictionaries/shell.wordlist.txt" }, { "name": "workspace", "path": "./cspell.dictionaries/workspace.wordlist.txt" } ], - // ignorePaths - a list of globs to specify which files are to be ignored - "ignorePaths": ["Cargo.lock", "target/**", "tests/**/fixtures/**", "src/uu/dd/test-resources/**", "vendor/**"], - // ignoreWords - a list of words to be ignored (even if they are in the flagWords) + + // files to ignore (globs supported) + "ignorePaths": [ + "Cargo.lock", + "target/**", + "tests/**/fixtures/**", + "src/uu/dd/test-resources/**", + "vendor/**" + ], + + // words to ignore (even if they are in the flagWords) "ignoreWords": [], - // words - list of words to be always considered correct + + // words to always consider correct "words": [] } From 3bfcf78c03fd30d6e5ddac900da9d044b949cebf Mon Sep 17 00:00:00 2001 From: Tillmann Rendel Date: Tue, 1 Feb 2022 23:38:18 +0100 Subject: [PATCH 5/5] Tweak comment in extensions.json To flush the highlighting cache. --- .vscode/extensions.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.vscode/extensions.json b/.vscode/extensions.json index 30b38bfa9..a02baee69 100644 --- a/.vscode/extensions.json +++ b/.vscode/extensions.json @@ -2,7 +2,7 @@ // see for the documentation about the extensions.json format { "recommendations": [ - // Rust language support. + // Rust language support "matklad.rust-analyzer", // `cspell` spell-checker support "streetsidesoftware.code-spell-checker"