Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 15 additions & 1 deletion tests/data/manifest.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Rules that are set for removal have not been included
rules:
000-US-spellcheck: # No value in a clean case for spelling
000-US-spellcheck:
cases:
- id: misspell
filetypes: [md, rst]
Expand All @@ -12,6 +12,20 @@ rules:
- wrod
- someting
severity: error
- id: ignore-rst
filetypes: [rst]
content: |
Ignore the :vale-ignore:`splelling` mistake.
expect:
triggers: []
severity: error
- id: ignore-md
filetypes: [md]
content: |
Ignore the {vale-ignore}`splelling` mistake.
expect:
triggers: []
severity: error
003-Ubuntu-names-versions:
cases:
- id: ubuntu-names-md
Expand Down
18 changes: 10 additions & 8 deletions vale.ini
Original file line number Diff line number Diff line change
Expand Up @@ -32,30 +32,32 @@ Canonical.025c-latinisms-to-avoid = suggestion
Canonical.400-Enforce-inclusive-terms = error
Canonical.500-Repeated-words = warning

TokenIgnores = ({vale-ignore}`.+?`), ({woke-ignore}`.+?`)

[*.md]
BasedOnStyles = Canonical

# Ignore custom spelling role
TokenIgnores = ({(vale-ignore|woke-ignore)}`.+?`)

# Ignore opening colon-fenced (:::) lines and colon-fenced literal directives
# The listed directives must be in sync with the [*.rst] `BlockIgnores`
BlockIgnores = (::::*[^\n]*), \
(?s)(::::*) *{(?:code-block|code|prompt|sourcecode|terminal|toctree)}[^\n]*\n(?:(?!\1$)[^\n]*\n)*\1 *


[*.rst]
BasedOnStyles = Canonical

# inline literal roles
# Ignore custom spelling role
TokenIgnores = (:(vale-ignore|woke-ignore):`.+?`)
# Ignore technical roles
TokenIgnores = (:relatedlinks:)
TokenIgnores = (:(command|envvar|file|kbd|literal|literalref|math|option|program|regexp|samp|token)?:`.+?`)
TokenIgnores = (:vale-ignore|woke-ignore:`.+?`)

# Directive names
# Ignore directives
TokenIgnores = (.. \w+::)
# Directive options
# Ignore options
TokenIgnores = (:\w+: \w+), (:\w+:)

# links defined elsewhere
# Ignore external links
TokenIgnores = (\`\w+\`_)

# Spelling not respecting code blocks
Expand Down