Allow '0'- and ' '-prefixed ordered list markers in MD005/MD029 (fixes #126).

This commit is contained in:
David Anson 2018-06-15 22:37:12 -07:00
parent 2710c375b3
commit 4a1e42d942
7 changed files with 190 additions and 8 deletions

View file

@ -15,3 +15,16 @@
Text
Text text
1. One
2. Two
3. Three
4. Four
5. Five
6. Six
7. Seven
8. Eight
9. Nine
10. Ten
11. Eleven
12. Twelve

View file

@ -39,6 +39,22 @@
"errorContext": null,
"errorRange": [1, 3]
},
{
"lineNumber": 23,
"ruleNames": [ "MD005", "list-indent" ],
"ruleDescription": "Inconsistent indentation for list items at the same level",
"errorDetail": "Expected: 1; Actual: 0",
"errorContext": null,
"errorRange": [1, 3]
},
{
"lineNumber": 29,
"ruleNames": [ "MD005", "list-indent" ],
"ruleDescription": "Inconsistent indentation for list items at the same level",
"errorDetail": "Expected: (3); Actual: (4)",
"errorContext": null,
"errorRange": [1, 5]
},
{
"lineNumber": 12,
"ruleNames": [ "MD006", "ul-start-left" ],

View file

@ -0,0 +1,96 @@
# List Alignment
## Leading Spaces
1. One
2. Two
3. Three
4. Four
5. Five
6. Six
7. Seven
8. Eight
9. Nine
10. Ten
11. Eleven
12. Twelve
## Leading Zeroes
01. One
02. Two
03. Three
04. Four
05. Five
06. Six
07. Seven
08. Eight
09. Nine
10. Ten
11. Eleven
12. Twelve
## Double Leading Zeroes
001. One
002. Two
003. Three
## Nested Lists
- Item
- Item
01. One
02. Two
03. Three
04. Four
05. Five
06. Six
07. Seven
08. Eight
09. Nine
10. Ten
11. Eleven
12. Twelve
- Item
- Item
1. One
2. Two
3. Three
4. Four
5. Five
6. Six
7. Seven
8. Eight
9. Nine
10. Ten
11. Eleven
12. Twelve
- Item
- Item
## Another Nested List
01. One
02. Two
01. One
02. Two
03. Three
04. Four
## Leading Spaces Errors
1. One
2. Two
3. Three
4. Four
5. Five {MD005}
6. Six
7. Seven
8. Eight
9. Nine
10. Ten
11. Eleven {MD005}
12. Twelve
13. Thirteen {MD005}
14. Fourteen