How to spellcheck only specific sections of a YAML document? #183
-
Hi, Just have a quick question regarding the usage of context filters. (and if its the correct way of using them) I have a yaml document in the following form title: Title
id: SomeID
description: Some description
references:
- https://google.com
data:
element1: process_creation
element2: windows
detection:
some_random_1:
- random1: 1
- random2: 2
some_random_2:
random|contains:
- 'A'
- 'B'
condition: this is a condition
other:
- some other things
final: something I wan spell check only some sections of the document mainly the description and title and some other fields. Is using the Appreciate your response in advance :) Thanks |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 4 replies
-
You could certainly try to use the Keep in mind that I do not have a specific filter for every file type out there, nor is my intention to as I am not familiar with every file type out there. That is why the plugin system exists. It might be more appropriate to write a filter specifically for a specific file type if something like I could even maybe see an argument for a YAML filter built into PySpelling as we already have the dependency, but work would have to be done to bring such a filter to light. |
Beta Was this translation helpful? Give feedback.
You could certainly try to use the
context
filter, if it works well enough, then I'd say go for it.Keep in mind that I do not have a specific filter for every file type out there, nor is my intention to as I am not familiar with every file type out there. That is why the plugin system exists. It might be more appropriate to write a filter specifically for a specific file type if something like
context
is not sufficient,. I could potentially see a plugin parsing YAML content with PyYAML and targeting specific sections, etc.I could even maybe see an argument for a YAML filter built into PySpelling as we already have the dependency, but work would have to be done to bring such a filter to …