Skip to content

Commit

Permalink
fix: Improve cspell.schema.json (#4815)
Browse files Browse the repository at this point in the history
  • Loading branch information
Jason3S committed Sep 10, 2023
1 parent 464ac7e commit 23f12e0
Show file tree
Hide file tree
Showing 20 changed files with 499 additions and 298 deletions.
133 changes: 85 additions & 48 deletions cspell.schema.json

Large diffs are not rendered by default.

5 changes: 2 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@
"test:bin-trace": "node ./bin.mjs trace test",
"test-build-docs": "cd doc-generator && pnpm i && pnpm run test-build-docs",
"test-integrations": "cd ./integration-tests && pnpm run integration-tests",
"test-schema": "ajv -s ./cspell.schema.json -d cspell.json -c ./packages/cspell-types/ajv.config.js",
"test-schema": "node ./test-packages/cspell-types/validate-schema/validate-schema.mjs",
"update-packages": "pnpm run update-packages-src && pnpm run update-packages-docs",
"update-packages-docs": "cd website && pnpm run update-packages",
"update-packages-src": "pnpm -r up",
Expand Down Expand Up @@ -87,6 +87,7 @@
"devDependencies": {
"@cspell/dict-markdown": "^2.0.1",
"@cspell/eslint-plugin": "workspace:*",
"@internal/scripts": "workspace:*",
"@lerna-lite/cli": "^2.5.0",
"@lerna-lite/publish": "^2.5.0",
"@rollup/plugin-alias": "^5.0.0",
Expand All @@ -101,7 +102,6 @@
"@typescript-eslint/eslint-plugin": "^5.62.0",
"@typescript-eslint/parser": "^5.62.0",
"@vitest/coverage-istanbul": "^0.34.4",
"ajv-cli": "^5.0.0",
"conventional-changelog-conventionalcommits": "^6.1.0",
"eslint": "^8.49.0",
"eslint-config-prettier": "^9.0.0",
Expand All @@ -119,7 +119,6 @@
"prettier": "^3.0.3",
"rollup": "^3.29.0",
"rollup-plugin-dts": "^5.3.1",
"shelljs": "^0.8.5",
"shx": "^0.3.4",
"ts-jest": "^29.1.1",
"ts2mjs": "^2.1.1",
Expand Down
14 changes: 7 additions & 7 deletions packages/cspell-eslint-plugin/assets/options.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,11 +39,11 @@
"properties": {
"allowCompoundWords": {
"default": false,
"description": "True to enable compound word checking. See [Case Sensitivity](https://cspell.org/docs/case-sensitive/) for more details.",
"description": "True to enable compound word checking. See https://cspell.org/docs/case-sensitive/ for more details.",
"type": "boolean"
},
"dictionaries": {
"description": "Optional list of dictionaries to use. Each entry should match the name of the dictionary.\n\nTo remove a dictionary from the list, add `!` before the name.\n\nFor example, `!typescript` will turn off the dictionary with the name `typescript`.\n\nSee the [Dictionaries](https://cspell.org/docs/dictionaries/) and [Custom Dictionaries](https://cspell.org/docs/dictionaries-custom/) for more details.",
"description": "Optional list of dictionaries to use. Each entry should match the name of the dictionary.",
"items": {
"description": "Reference to a dictionary by name. One of:\n- {@link DictionaryRef } \n- {@link DictionaryNegRef }",
"type": "string"
Expand Down Expand Up @@ -85,7 +85,7 @@
},
"type": {
"default": "S",
"description": "Type of file: S - single word per line, W - each line can contain one or more words separated by space, C - each line is treated like code (Camel Case is allowed). Default is S. C is the slowest to load due to the need to split each line based upon code splitting rules.",
"description": "Type of file:\n- S - single word per line,\n- W - each line can contain one or more words separated by space,\n- C - each line is treated like code (Camel Case is allowed).\n\nDefault is S.\n\nC is the slowest to load due to the need to split each line based upon code splitting rules.",
"enum": [
"S",
"W",
Expand All @@ -111,14 +111,14 @@
"type": "boolean"
},
"flagWords": {
"description": "List of words to always be considered incorrect. Words found in `flagWords` override `words`.\n\nFormat of `flagWords`\n- single word entry - `word`\n- with suggestions - `word:suggestion` or `word->suggestion, suggestions`\n\nExample: ```ts \"flagWords\": [ \"color: colour\", \"incase: in case, encase\", \"canot->cannot\", \"cancelled->canceled\" ] ```",
"description": "List of words to always be considered incorrect. Words found in `flagWords` override `words`.",
"items": {
"type": "string"
},
"type": "array"
},
"ignoreRegExpList": {
"description": "List of regular expression patterns or pattern names to exclude from spell checking.\n\nExample: `[\"href\"]` - to exclude html href pattern.\n\nRegular expressions use JavaScript regular expression syntax.\n\nExample: to ignore ALL-CAPS words\n\nJSON ```json \"ignoreRegExpList\": [\"/\\\\b[A-Z]+\\\\b/g\"] ```\n\nYAML ```yaml ignoreRegExpList: - >- /\\b[A-Z]+\\b/g ```\n\nBy default, several patterns are excluded. See [Configuration](https://cspell.org/configuration/patterns) for more details.\n\nWhile you can create your own patterns, you can also leverage several patterns that are [built-in to CSpell](https://cspell.org/types/cspell-types/types/PredefinedPatterns.html).",
"description": "List of regular expression patterns or pattern names to exclude from spell checking.",
"items": {
"description": "A PatternRef is a Pattern or PatternId.",
"type": "string"
Expand Down Expand Up @@ -146,10 +146,10 @@
"type": "array"
}
],
"description": "Allows this configuration to inherit configuration for one or more other files.\n\nSee [Importing / Extending Configuration](https://cspell.org/configuration/imports/) for more details."
"description": "Allows this configuration to inherit configuration for one or more other files.\n\nSee https://cspell.org/configuration/imports/ for more details."
},
"includeRegExpList": {
"description": "List of regular expression patterns or defined pattern names to match for spell checking.\n\nIf this property is defined, only text matching the included patterns will be checked.\n\nWhile you can create your own patterns, you can also leverage several patterns that are [built-in to CSpell](https://cspell.org/types/cspell-types/types/PredefinedPatterns.html).",
"description": "List of regular expression patterns or defined pattern names to match for spell checking.",
"items": {
"description": "A PatternRef is a Pattern or PatternId.",
"type": "string"
Expand Down
1 change: 0 additions & 1 deletion packages/cspell-tools/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,6 @@
},
"devDependencies": {
"@types/glob": "^8.1.0",
"@types/shelljs": "^0.8.12",
"lorem-ipsum": "^2.0.8",
"ts-json-schema-generator": "^1.3.0"
},
Expand Down
11 changes: 0 additions & 11 deletions packages/cspell-types/ajv.config.js

This file was deleted.

0 comments on commit 23f12e0

Please sign in to comment.