forked from project-chip/connectedhomeip
-
Notifications
You must be signed in to change notification settings - Fork 2
/
.spellcheck.yml
70 lines (66 loc) · 2.23 KB
/
.spellcheck.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
# Copyright (c) 2020-2021 Project CHIP Authors
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# To run locally:
# Prerequisits (only once):
#
# apt-get install aspell aspell-en
# pip install pyspelling
#
# Actual run:
#
# pyspelling pyspelling --config .spellcheck.yml
matrix:
- name: markdown
dictionary:
wordlists:
- .github/.wordlist.txt
pipeline:
# See https://facelessuser.github.io/pyspelling/configuration/#pipeline
# and https://facelessuser.github.io/pyspelling/filters/context/
# context-aware logic: we have a LOT of code examples in markdown,
# avoid trying to spellcheck code.
- pyspelling.filters.context:
context_visible_first: true
escapes: \\[\\`~]
delimiters:
# Ignore multiline content between fences (fences can have 3 or more back ticks)
# ```
# content
# ```
#
# Allows language marker (since github allows it) like:
# ```python
# content
# ```
#
# Allow MyST extended syntax like:
# ```{include} my/file.md
# ```
- open: '(?s)^(?P<open> *`{3,})([a-z]*$|{[a-z]*?}\s*[^\n]*?$)'
close: '^(?P=open)$'
# Ignore text between inline back ticks
- open: '(?P<open>`+)'
close: '(?P=open)'
# Ignore URL in hyperlinks [title](url)
- open: '\[[^]]*\]\('
close: '\)'
# Ignore code markers
- open: '<code>'
close: '</code>'
# converts markdown to HTML
- pyspelling.filters.markdown:
sources:
- '**/*.md|!third_party/**|!examples/common/**/repo/**|!docs/ERROR_CODES.md'
aspell:
ignore-case: true