|
8 | 8 | "extends": null, |
9 | 9 |
|
10 | 10 | // MD001/heading-increment/header-increment - Heading levels should only increment by one level at a time |
| 11 | + // Enforces bullet 1 of https://docs.ipfs.tech/community/contribute/grammar-formatting-and-style/#titles |
11 | 12 | "MD001": true, |
12 | 13 |
|
13 | 14 | // MD003/heading-style/header-style - Heading style |
| 15 | + // Pretty sure we do this implicitly |
| 16 | + // Enforces a heading style like the following |
| 17 | + // |
| 18 | + // # Title |
| 19 | + // ## Subheading |
14 | 20 | "MD003": { |
15 | 21 | // Heading style |
16 | 22 | "style": "atx" |
17 | 23 | }, |
18 | 24 |
|
19 | 25 | // MD004/ul-style - Unordered list style |
| 26 | + // Enforces https://docs.ipfs.tech/community/contribute/grammar-formatting-and-style/#unordered-lists |
20 | 27 | "MD004": { |
21 | 28 | // List style |
22 | 29 | "style": "dash" |
23 | 30 | }, |
24 | 31 |
|
25 | 32 | // MD005/list-indent - Inconsistent indentation for list items at the same level |
| 33 | + // Seems implicitly related to https://docs.ipfs.tech/community/contribute/grammar-formatting-and-style/#unordered-lists |
26 | 34 | "MD005": true, |
27 | 35 |
|
28 | 36 | // MD007/ul-indent - Unordered list indentation |
| 37 | + // Pretty sure we enforce 2 spaces indnetation |
29 | 38 | "MD007": { |
30 | 39 | // Spaces for indent |
31 | 40 | "indent": 2, |
|
36 | 45 | }, |
37 | 46 |
|
38 | 47 | // MD009/no-trailing-spaces - Trailing spaces |
| 48 | + // Seems like something good to have |
39 | 49 | "MD009": { |
40 | 50 | // Spaces for line break |
41 | 51 | "br_spaces": 2, |
|
46 | 56 | }, |
47 | 57 |
|
48 | 58 | // MD010/no-hard-tabs - Hard tabs |
| 59 | + // Not sure if we want to enforce this, seems like it would be a good idea? |
49 | 60 | "MD010": false, |
50 | 61 |
|
51 | 62 | // MD011/no-reversed-links - Reversed link syntax |
| 63 | + // Seems obvious, probably good to enforce |
52 | 64 | "MD011": true, |
53 | 65 |
|
54 | 66 | // MD012/no-multiple-blanks - Multiple consecutive blank lines |
| 67 | + // Seems obvious, probably good to enforce |
55 | 68 | "MD012": true, |
56 | 69 |
|
57 | 70 | // MD013/line-length - Line length |
| 71 | + // Very much unsure on this one |
58 | 72 | "MD013": { |
59 | 73 | // Number of characters |
60 | 74 | "line_length": 80, |
|
77 | 91 | }, |
78 | 92 |
|
79 | 93 | // MD014/commands-show-output - Dollar signs used before commands without showing output |
| 94 | + // Seems obvious, probably good to enforce |
80 | 95 | "MD014": true, |
81 | 96 |
|
82 | 97 | // MD018/no-missing-space-atx - No space after hash on atx style heading |
| 98 | + // Seems to be something we already do anyways |
83 | 99 | "MD018": true, |
84 | 100 |
|
85 | 101 | // MD019/no-multiple-space-atx - Multiple spaces after hash on atx style heading |
| 102 | + // Seems to be something we already do anyways |
86 | 103 | "MD019": true, |
87 | 104 |
|
88 | 105 | // MD020/no-missing-space-closed-atx - No space inside hashes on closed atx style heading |
| 106 | + // Seems irrelvant since we are using atxc headings |
89 | 107 | "MD020": false, |
90 | 108 |
|
91 | 109 | // MD021/no-multiple-space-closed-atx - Multiple spaces inside hashes on closed atx style heading |
| 110 | + // Seems irrelvant since we are using atxc headings |
92 | 111 | "MD021": false, |
93 | 112 |
|
94 | 113 | // MD022/blanks-around-headings/blanks-around-headers - Headings should be surrounded by blank lines |
| 114 | + // Seems to be something we already do anyways |
95 | 115 | "MD022": { |
96 | 116 | // Blank lines above heading |
97 | 117 | "lines_above": 1, |
|
100 | 120 | }, |
101 | 121 |
|
102 | 122 | // MD023/heading-start-left/header-start-left - Headings must start at the beginning of the line |
| 123 | + // Seems to be something we already do anyways |
103 | 124 | "MD023": true, |
104 | 125 |
|
105 | 126 | // MD024/no-duplicate-heading/no-duplicate-header - Multiple headings with the same content |
| 127 | + // Seems to be a good practice |
106 | 128 | "MD024": { |
107 | 129 | // Only check sibling headings |
108 | | - "allow_different_nesting": false, |
109 | | - // Only check sibling headings |
| 130 | + // Added this in case we start doing changelogs |
110 | 131 | "siblings_only": true |
111 | 132 | }, |
112 | 133 |
|
113 | 134 | // MD025/single-title/single-h1 - Multiple top-level headings in the same document |
| 135 | + // Enforces bullet 2 of https://docs.ipfs.tech/community/contribute/grammar-formatting-and-style/#titles |
114 | 136 | "MD025": { |
115 | 137 | // Heading level |
116 | 138 | "level": 1, |
117 | 139 | // RegExp for matching title in front matter |
118 | | - "front_matter_title": "" |
| 140 | + "front_matter_title": "^\\s*title\\s*[:=]" |
119 | 141 | }, |
120 | 142 |
|
121 | 143 | // MD026/no-trailing-punctuation - Trailing punctuation in heading |
| 144 | + // Enforces bullet 3 of https://docs.ipfs.tech/community/contribute/grammar-formatting-and-style/#titles |
122 | 145 | "MD026": { |
123 | 146 | // Punctuation characters |
124 | 147 | "punctuation": ".,;:!。,;:!" |
125 | 148 | }, |
126 | 149 |
|
127 | 150 | // MD027/no-multiple-space-blockquote - Multiple spaces after blockquote symbol |
| 151 | + // Seems like a good practice |
128 | 152 | "MD027": true, |
129 | 153 |
|
130 | 154 | // MD028/no-blanks-blockquote - Blank line inside blockquote |
| 155 | + // Seems like a good practice |
131 | 156 | "MD028": true, |
132 | 157 |
|
133 | 158 | // MD029/ol-prefix - Ordered list item prefix |
| 159 | + // Pretty sure we enforce this without calling it out |
| 160 | + // |
| 161 | + // 1. |
| 162 | + // 1. |
| 163 | + // 1. |
134 | 164 | "MD029": { |
135 | 165 | // List style |
136 | 166 | "style": "one" |
137 | 167 | }, |
138 | 168 |
|
139 | 169 | // MD030/list-marker-space - Spaces after list markers |
| 170 | + // Seems like we already do this |
140 | 171 | "MD030": { |
141 | 172 | // Spaces for single-line unordered list items |
142 | 173 | "ul_single": 1, |
|
149 | 180 | }, |
150 | 181 |
|
151 | 182 | // MD031/blanks-around-fences - Fenced code blocks should be surrounded by blank lines |
| 183 | + // Seems like a good practice / we already do this |
152 | 184 | "MD031": { |
153 | 185 | // Include list items |
154 | 186 | "list_items": true |
155 | 187 | }, |
156 | 188 |
|
157 | 189 | // MD032/blanks-around-lists - Lists should be surrounded by blank lines |
| 190 | + // Seems like a good practice / we already do this |
158 | 191 | "MD032": true, |
159 | 192 |
|
160 | 193 | // MD033/no-inline-html - Inline HTML |
| 194 | + // Not sure about this one - do we need to allow any html elements? |
| 195 | + |
161 | 196 | "MD033": { |
162 | 197 | // Allowed elements |
163 | 198 | "allowed_elements": [] |
164 | 199 | }, |
165 | 200 |
|
166 | 201 | // MD034/no-bare-urls - Bare URL used |
| 202 | + // Pretty sure we don't enforce this, but I think it would be a good idea |
167 | 203 | // TODO remove all bare URLS from docs |
168 | 204 | // We should not have bare urls in the docs |
169 | 205 | // Once done, set this to true |
170 | 206 | "MD034": false, |
171 | 207 |
|
172 | 208 | // MD035/hr-style - Horizontal rule style |
| 209 | + // Not sure if this matters |
173 | 210 | "MD035": { |
174 | 211 | // Horizontal rule style |
175 | 212 | "style": "consistent" |
176 | 213 | }, |
177 | 214 |
|
178 | 215 | // MD036/no-emphasis-as-heading/no-emphasis-as-header - Emphasis used instead of a heading |
| 216 | + // Seems like a good rule to have in place |
179 | 217 | "MD036": { |
180 | 218 | // Punctuation characters |
181 | 219 | "punctuation": ".,;:!?。,;:!?" |
182 | 220 | }, |
183 | 221 |
|
184 | 222 | // MD037/no-space-in-emphasis - Spaces inside emphasis markers |
| 223 | + // Seems like a good rule to have in place |
185 | 224 | "MD037": true, |
186 | 225 |
|
187 | 226 | // MD038/no-space-in-code - Spaces inside code span elements |
| 227 | + // Seems like a good rule to have in place |
188 | 228 | "MD038": true, |
189 | 229 |
|
190 | 230 | // MD039/no-space-in-links - Spaces inside link text |
| 231 | + // Seems like a good rule to have in place |
191 | 232 | "MD039": true, |
192 | 233 |
|
193 | 234 | // MD040/fenced-code-language - Fenced code blocks should have a language specified |
| 235 | + // Seems like we already do this |
194 | 236 | "MD040": true, |
195 | 237 |
|
196 | 238 | // MD041/first-line-heading/first-line-h1 - First line in a file should be a top-level heading |
| 239 | + // Enforces https://docs.ipfs.tech/community/contribute/grammar-formatting-and-style/#titles |
197 | 240 | "MD041": { |
198 | 241 | // Heading level |
199 | 242 | "level": 1, |
|
202 | 245 | }, |
203 | 246 |
|
204 | 247 | // MD042/no-empty-links - No empty links |
| 248 | + // Seems like a good rule to have in place |
205 | 249 | "MD042": true, |
206 | 250 |
|
207 | 251 | // MD043/required-headings/required-headers - Required heading structure |
|
217 | 261 | // MD044/proper-names - Proper names should have the correct capitalization |
218 | 262 | // TODO |
219 | 263 | // Determine if we want to use this, |
| 264 | + // Could be use for things like JavaScript, Python, LibP2P, etc. |
220 | 265 | // May cause issues |
221 | 266 | "MD044": { |
222 | 267 | // List of proper names |
223 | 268 | "names": [], |
224 | 269 | // Include code blocks |
225 | | - "code_blocks": true, |
| 270 | + "code_blocks": false, |
226 | 271 | // Include HTML elements |
227 | | - "html_elements": true |
| 272 | + "html_elements": false |
228 | 273 | }, |
229 | 274 |
|
230 | 275 | // MD045/no-alt-text - Images should have alternate text (alt text) |
| 276 | + // Enforces https://docs.ipfs.tech/community/contribute/grammar-formatting-and-style/#alt-text |
231 | 277 | "MD045": true, |
232 | 278 |
|
233 | 279 | // MD046/code-block-style - Code block style |
| 280 | + // Seems like we already enforce this |
234 | 281 | "MD046": { |
235 | 282 | // Block style |
236 | 283 | "style": "fenced" |
237 | 284 | }, |
238 | 285 |
|
239 | 286 | // MD047/single-trailing-newline - Files should end with a single newline character |
| 287 | + // Not sure if we enforce this, but seems like a good practice |
240 | 288 | "MD047": true, |
241 | 289 |
|
242 | 290 | // MD048/code-fence-style - Code fence style |
| 291 | + // Seems like we already enforce this |
243 | 292 | "MD048": { |
244 | 293 | // Code fence style |
245 | 294 | "style": "backtick" |
246 | 295 | }, |
247 | 296 |
|
248 | 297 | // MD049/emphasis-style - Emphasis style should be consistent |
| 298 | + // Enforces https://docs.ipfs.tech/community/contribute/grammar-formatting-and-style/#italics |
249 | 299 | "MD049": { |
250 | 300 | // Emphasis style should be consistent |
251 | 301 | "style": "underscore" |
252 | 302 | }, |
253 | 303 |
|
254 | 304 | // MD050/strong-style - Strong style should be consistent |
| 305 | + // Enforces https://docs.ipfs.tech/community/contribute/grammar-formatting-and-style/#bold-text |
255 | 306 | "MD050": { |
256 | 307 | // Strong style should be consistent |
257 | 308 | "style": "asterisk" |
258 | 309 | }, |
259 | 310 |
|
260 | 311 | // MD051/link-fragments - Link fragments should be valid |
| 312 | + // Seems like a good rule, markdow-link-check should also catch this |
261 | 313 | "MD051": true, |
262 | 314 |
|
263 | 315 | // MD052/reference-links-images - Reference links and images should use a label that is defined |
|
0 commit comments