Spell check only specification/**, match spell checking behavior with SpellCheck - All#32195
Merged
danieljurek merged 20 commits intomainfrom Jan 17, 2025
Merged
Spell check only specification/**, match spell checking behavior with SpellCheck - All#32195danieljurek merged 20 commits intomainfrom
danieljurek merged 20 commits intomainfrom
Conversation
Next Steps to Merge✅ All automated merging requirements have been met! To get your PR merged, see aka.ms/azsdk/specreview/merge. |
|
PR validation pipeline restarted successfully. If there is ApiView generated, it will be updated in this comment. |
This reverts commit b9ae212.
mikeharder
reviewed
Jan 16, 2025
cspell.yaml
Outdated
| - cspell.yaml | ||
| - node_modules/** | ||
|
|
||
| # Exclude all files in the repo which aren't in specification/. cspell does |
Member
There was a problem hiding this comment.
Can we use glob pattern * to match all files in root without listing them individually? I agree we'll need to list each folder in root using foo/**.
mikeharder
approved these changes
Jan 16, 2025
…on to test error behavior
ZhidaLiu
pushed a commit
to ZhidaLiu/azure-rest-api-specs
that referenced
this pull request
Jan 22, 2025
… SpellCheck - All (Azure#32195) Spell check only specification/**, match spell check behavior with SpellCheck - All
markcowl
pushed a commit
to markcowl/azure-rest-api-specs
that referenced
this pull request
Feb 6, 2025
… SpellCheck - All (Azure#32195) Spell check only specification/**, match spell check behavior with SpellCheck - All
najian
pushed a commit
to najian/azure-rest-api-specs
that referenced
this pull request
Mar 4, 2025
… SpellCheck - All (Azure#32195) Spell check only specification/**, match spell check behavior with SpellCheck - All
pjpatel12
pushed a commit
to pjpatel12/azure-rest-api-specs
that referenced
this pull request
Apr 29, 2025
… SpellCheck - All (Azure#32195) Spell check only specification/**, match spell check behavior with SpellCheck - All
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Current cspell config is generating too many errors in non
specification/folders. Most value is created when cspell scansspecification/. This PR scopes cspell to check only files in thespecification/folder.cspell does not support
!specification/**so the exclusions are crude. If a PR is opened which introduces a new file into the root of the repo, spell check will fail on spelling error detections.Tests
SpellCheck
Errors in both
specification/(included) anddocumentation/(excluded) folder (note only errors described are inspecification/and none fromdocumentation/: https://github.com/Azure/azure-rest-api-specs/actions/runs/12822906068/job/35756574727?pr=32195#step:3:41No errors in PR: https://github.com/Azure/azure-rest-api-specs/actions/runs/12822920970/job/35756614201
SpellCheck - All
Spell Check - All with errors in both
specification/anddocumentation/(note only errors described are inspecification/and notdocumentation/): https://github.com/Azure/azure-rest-api-specs/actions/runs/12822909744/job/35756584823#step:3:34414Spell Check - All with no errors: https://github.com/Azure/azure-rest-api-specs/actions/runs/12822928529/job/35756633557
Other info
Another perk: because the
cspell.yamlandcspell.jsonfiles are still in the root of the repo you get spell checking of files outside of thespecification/cone in vscode if you have the spell check extension:Globbing does not fully support negations because the
node-globlibrary used does not: https://cspell.org/docs/globs/ (search for!)The
ignorePathsincspell.yamlinvolving directories are evaluated from the root of the config file... Sonode_modules/**will not excludenode_modules/**folders found inspecification/, it will only exclude them if they're found in the same folder as the declaringcspell.yamlthat excludes them. However, filenames likecspell.yamlare ignored wherever they are found.