-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Ignoring multiple error messages #11
Comments
Multiple validation messages can be skipped using a regex with "or" operators in the For example, the command:
will ignore the following 3 types of validation messages:
Because of the spaces in the search text, be sure to wrap the entire |
Oh, good to know! It's definitely something worth adding to the readme. But the convenience and readability/maintainability of that kind of filtering is questionable 😅 I hope you'd consider supporting an ignore file. Thanks! |
The proposed solution is to supplement the current See documentation at: I named the flag I considered a few different JSON structures because JSON is safer than a raw text file, but I just couldn't figure out a JSON structure with comments that I liked more than raw text. The fact that you can't put real comments in JSON is really annoying. Anyway, the code is not yet released, and if you have any suggestions for improvements please let me know. Otherwise, the feature works and is ready to release. |
I like the # Comment
- Trailing slash on void elements
# Comment
- /^Duplicate ID/
# Comment
- /^Element .blockquote. not allowed/ |
The config file has been updated to support both strings and regex, like in the above YAML example. Regex lines now have to be wrapped in slashes, but I think this actually makes the config file easier to read. Between text, JSON, and YAML for config, none are awesome, but text for a simple list of patterns seems the cleanest. |
Oh, nice! That was super quick. Thank you for implementing this feature, I’m already using it :) |
Hello! I’m glad I found your validator: it’s simple enough for my needs compared to the original vnu one. One of the reasons to start looking for another tool was the vnu’s problems with filtering out error messages. It’s just unreliable: some work fine, some just don’t. But in your case, it seems to be working exceptionally well :)
Unfortunately, I need to filter out multiple error messages, and it’s unclear from the readme how to achieve that or if it’s even possible. I tried using multiple
--ignore
keys or combining strings into a single one, no luck so far.The best solution would be to support a simple config file with exceptions, like vnu does:
I hope you can clarify this in the readme or consider supporting an ignore file. Thank you!
The text was updated successfully, but these errors were encountered: