Skip to content

Commit 12e6b38

Browse files
committed
New cspell baseline + SpellCheck - All workflow
1 parent 2718ebc commit 12e6b38

File tree

282 files changed

+9187
-33
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

282 files changed

+9187
-33
lines changed

.github/workflows/spelling-all.yaml

+30
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: SpellCheck - All
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
- RPSaaSMaster
8+
9+
schedule:
10+
# Run every day at 12:06 UTC
11+
- cron: "6 12 * * *"
12+
workflow_dispatch:
13+
14+
jobs:
15+
spellcheck:
16+
name: SpellCheck
17+
runs-on: ubuntu-latest
18+
19+
steps:
20+
- name: Checkout repository
21+
uses: actions/checkout@v4
22+
with:
23+
fetch-depth: 1
24+
25+
- name: Run spelling check
26+
run: |
27+
./eng/common/spelling/Invoke-Cspell.ps1 `
28+
-ScanGlobs 'specification/**' `
29+
-CSpellConfigPath './cspell.json'
30+
shell: pwsh

.github/workflows/spelling.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
- name: Run spelling check
1717
run: |
1818
./eng/common/scripts/check-spelling-in-changed-files.ps1 `
19-
-CSpellConfigPath 'cSpell.json' `
19+
-CSpellConfigPath 'cspell.json' `
2020
-SourceCommittish HEAD `
2121
-TargetCommittish HEAD^ `
2222
-ExitWithError

cspell.json

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
{
2+
"//purpose": "This file is needed for older spell check versions to specify the files to lint",
3+
"version": "0.2",
4+
"import": [
5+
"cspell.yaml"
6+
]
7+
}

cspell.yaml

+51-3
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,11 @@
1-
version: "0.2"
1+
version: '0.2'
22
language: en
3-
words: []
43
flagWords:
54
- teh
65
ignorePaths:
76
- '**/examples/**'
87
- '**/package-lock.json'
9-
- cSpell.json
8+
- cspell.json
109
- eng/**
1110
- node_modules/**
1211
ignoreRegExpList:
@@ -29,3 +28,52 @@ enableFiletypes:
2928
- cadl
3029
ignoreWords:
3130
- trafficcontrollerspec
31+
words:
32+
- autorest
33+
- autoscale
34+
- azext
35+
- byos
36+
- cadl
37+
- codegen
38+
- contoso
39+
- datacenter
40+
- dataplane
41+
- deallocate
42+
- deallocated
43+
- eastus
44+
- entra
45+
- fqdns
46+
- hana
47+
- innererror
48+
- keyvault
49+
- kusto
50+
- liftr
51+
- localizable
52+
- managedidentity
53+
- maxpagesize
54+
- mbps
55+
- mgmt
56+
- modelerfour
57+
- multiapi
58+
- multiapiscript
59+
- odata
60+
- onboarded
61+
- payg
62+
- privatelinks
63+
- privatepreview
64+
- providerhub
65+
- regen
66+
- resourcegroups
67+
- resourcemanager
68+
- rpaas
69+
- rulesets
70+
- skiptoken
71+
- skus
72+
- somefile
73+
- subresource
74+
- substatus
75+
- typespec
76+
- upsert
77+
- vmss
78+
- vnet
79+
- westus

documentation/ci-fix.md

+28-29
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ If you need help with your specs PR, please first thoroughly read the [aka.ms/az
4141
- [`Swagger PrettierCheck`](#swagger-prettiercheck)
4242
- [Prettier reference](#prettier-reference)
4343
- [`Swagger SemanticValidation`](#swagger-semanticvalidation)
44-
- [`Swagger SpellCheck`](#swagger-spellcheck)
44+
- [`Spell Check`](#spell-check)
4545
- [`TypeSpec Validation`](#typespec-validation)
4646
- [Run `tsv` locally](#run-tsv-locally)
4747
- [`license/cla`](#licensecla)
@@ -113,7 +113,7 @@ Various APIViews are generated as part of the Azure REST API specs PR build. Amo
113113
### If an expected APIView was not generated, follow the step below to troubleshoot.
114114

115115
- On the CI check click on `details` > `View Azure DevOps build log for more details` to view the devOps logs.
116-
- Investigate the CI job for the languge with error. TypeSpec and Swagger APIViews are generated as part of the `AzureRestApiSpecsPipeline` stage in the `TypeSpecAPIView` and `SwaggerAPIView` jobs respectively, while APIViews for other SDK languges are generated in their respective language jobs in the `SDK Automation` stage.
116+
- Investigate the CI job for the language with error. TypeSpec and Swagger APIViews are generated as part of the `AzureRestApiSpecsPipeline` stage in the `TypeSpecAPIView` and `SwaggerAPIView` jobs respectively, while APIViews for other SDK languages are generated in their respective language jobs in the `SDK Automation` stage.
117117
- Ensure that all previous checks in the job are green before proceeding.
118118

119119
### Diagnosing APIView failure for SDK Language (not Swagger or TypeSpec)
@@ -247,35 +247,34 @@ oav validate-spec <openapi-spec-path>
247247
Please see [readme](https://github.com/Azure/oav/blob/bd04e228b4181c53769ed88e561dec5212e77253/README.md) for how to install or run tool in details.
248248
Refer to [Semantic and Model Violations Reference](https://github.com/Azure/azure-rest-api-specs/blob/main/documentation/Semantic-and-Model-Violations-Reference.md) for detailed description of validations and how-to-fix guidance.
249249

250-
## `Swagger SpellCheck`
251-
252-
If you receive a spelling failure either fix the spelling to match or if there are words that need to be suppressed for your service then add the word to the override list in [cspell.json](https://github.com/Azure/azure-rest-api-specs/blob/main/cSpell.json). Either
253-
add to your existing section or create a new section for your specific spec or service family if the work is more generally used in lots of files under your service.
254-
255-
``` yaml
256-
"overrides": [
257-
... example of specific file override
258-
{
259-
"filename": "**/specification/hdinsight/resource-manager/Microsoft.HDInsight/preview/2015-03-01-preview/cluster.json",
260-
"words": [
261-
"saskey"
262-
]
263-
}
264-
... example of specific service family override
265-
{
266-
"filename": "**/specification/cognitiveservices/**/*.json",
267-
"words": [
268-
"flac",
269-
"mpga"
270-
]
271-
}
250+
## Spell Check
251+
252+
If you receive a spelling failure either fix the spelling in source. If there are words that need to be suppressed for
253+
your service, add the word to the override list in the `words` list in the `specification/<service>/cspell.json`
254+
file for your service.
255+
256+
If the `specification/<service>/cspell.json` file does not exist, create it using the example below and set the `words`
257+
list to the words that need to be suppressed. Both `version` and `import` fields are required, use the values in the
258+
example.
259+
260+
For example (note the words list is sorted alphabetically):
261+
262+
```json
263+
{
264+
"version": "0.2",
265+
"import": [
266+
"../../cspell.json"
267+
],
268+
"words": [
269+
"aardvark",
270+
"zoology"
271+
]
272+
}
272273
```
273274

274-
Words are case-insensitive so use lower case for the word list.
275+
Words are case-insensitive so you only need to add the word once.
275276

276-
If you need more information on see [cspell configuration](https://cspell.org/configuration/).
277-
278-
*Note*: We are trying to move away from one shared dictionary file so try and avoid editing custom-words.txt in the root as it will likely go away in the future.
277+
For more information see [cspell configuration](https://cspell.org/configuration/).
279278

280279
## `TypeSpec Validation`
281280

@@ -313,4 +312,4 @@ Following checks have been removed from the validation toolchain as of August 20
313312
[APIView Support Teams Channel]: https://teams.microsoft.com/l/channel/19%3A3adeba4aa1164f1c889e148b1b3e3ddd%40thread.skype/APIView?groupId=3e17dcb0-4257-4a30-b843-77f47f1d4121&tenantId=72f988bf-86f1-41af-91ab-2d7cd011db47
314313
[automated validation tooling]: https://eng.ms/docs/products/azure-developer-experience/design/api-specs/api-tooling
315314
[Azure REST API specs PR]: https://eng.ms/docs/products/azure-developer-experience/design/api-specs-pr/api-specs-pr
316-
[TypeSpec Discussions Teams channel]: https://teams.microsoft.com/l/channel/19%3A906c1efbbec54dc8949ac736633e6bdf%40thread.skype/TypeSpec%20Discussion%20%F0%9F%90%AE?groupId=3e17dcb0-4257-4a30-b843-77f47f1d4121&tenantId=72f988bf-86f1-41af-91ab-2d7cd011db47
315+
[TypeSpec Discussions Teams channel]: https://teams.microsoft.com/l/channel/19%3A906c1efbbec54dc8949ac736633e6bdf%40thread.skype/TypeSpec%20Discussion%20%F0%9F%90%AE?groupId=3e17dcb0-4257-4a30-b843-77f47f1d4121&tenantId=72f988bf-86f1-41af-91ab-2d7cd011db47
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# This file configures spell checking. Items in "words" were initially populated
2+
# with words that might be spelling errors. Review these words and take
3+
# appropriate action. For more information, see: https://aka.ms/ci-fix#spell-check
4+
5+
# Spell checking is not case sensitive
6+
# Keep word lists in alphabetical so the file is easier to manage
7+
version: '0.2'
8+
import:
9+
- ../../cspell.yaml
10+
words:
11+
- enterpriseknowledgegraphservice
12+

specification/addons/cspell.yaml

+12
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# This file configures spell checking. Items in "words" were initially populated
2+
# with words that might be spelling errors. Review these words and take
3+
# appropriate action. For more information, see: https://aka.ms/ci-fix#spell-check
4+
5+
# Spell checking is not case sensitive
6+
# Keep word lists in alphabetical so the file is easier to manage
7+
version: '0.2'
8+
import:
9+
- ../../cspell.yaml
10+
words:
11+
- armaddons
12+
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
# This file configures spell checking. Items in "words" were initially populated
2+
# with words that might be spelling errors. Review these words and take
3+
# appropriate action. For more information, see: https://aka.ms/ci-fix#spell-check
4+
5+
# Spell checking is not case sensitive
6+
# Keep word lists in alphabetical so the file is easier to manage
7+
version: '0.2'
8+
import:
9+
- ../../cspell.yaml
10+
words:
11+
- addomain
12+
- addomainservicemembers
13+
- addsservicemembers
14+
- addsservices
15+
- adfs
16+
- adhybridhealthservice
17+
- alertfeedback
18+
- availibility
19+
- badpassword
20+
- continuationtoken
21+
- datafreshness
22+
- exporterrors
23+
- exportstatus
24+
- extranet
25+
- feedbacktype
26+
- forestsummary
27+
- globalconfiguration
28+
- hotfixes
29+
- metricmetadata
30+
- modififed
31+
- monitoringconfiguration
32+
- monitoringconfigurations
33+
- mpping
34+
- multivalued
35+
- occured
36+
- onboards
37+
- onpremises
38+
- qfes
39+
- replicationdetails
40+
- replicationstatus
41+
- replicationsummary
42+
- serviceconfiguration
43+
- servicemembers
44+
- sysvol
45+
- userpreference
46+
overrides:
47+
- filename: >-
48+
**/specification/adhybridhealthservice/resource-manager/Microsoft.ADHybridHealthService/stable/2014-01-01/ADHybridHealthService.json
49+
words:
50+
- addomain
51+
- availibility
52+
- modififed
53+
- mpping
54+
- occured
55+

specification/advisor/cspell.yaml

+14
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# This file configures spell checking. Items in "words" were initially populated
2+
# with words that might be spelling errors. Review these words and take
3+
# appropriate action. For more information, see: https://aka.ms/ci-fix#spell-check
4+
5+
# Spell checking is not case sensitive
6+
# Keep word lists in alphabetical so the file is easier to manage
7+
version: '0.2'
8+
import:
9+
- ../../cspell.yaml
10+
words:
11+
- armadvisor
12+
- asssignment
13+
- unlocalized
14+

specification/agrifood/cspell.yaml

+28
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
# This file configures spell checking. Items in "words" were initially populated
2+
# with words that might be spelling errors. Review these words and take
3+
# appropriate action. For more information, see: https://aka.ms/ci-fix#spell-check
4+
5+
# Spell checking is not case sensitive
6+
# Keep word lists in alphabetical so the file is easier to manage
7+
version: '0.2'
8+
import:
9+
- ../../cspell.yaml
10+
words:
11+
- adma
12+
- agfood
13+
- agri
14+
- agrifood
15+
- dailyforecast
16+
- dailyhistorical
17+
- discoverability
18+
- farmbeats
19+
- johndeere
20+
- madma
21+
- ndvi
22+
- ndwi
23+
- retryable
24+
- shapefile
25+
- shapefiles
26+
- sinergise
27+
- stac
28+

0 commit comments

Comments
 (0)