Skip to content
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

Unable to ignore URL in YAML with TokenIgnores #402

Closed
rachelrice opened this issue Feb 2, 2022 · 2 comments
Closed

Unable to ignore URL in YAML with TokenIgnores #402

rachelrice opened this issue Feb 2, 2022 · 2 comments

Comments

@rachelrice
Copy link

With macOS, Vale installed via Homebrew, Vale version 2.14.0

With .vale.ini:

StylesPath = styles
MinAlertLevel = suggestion

[*.yaml]
BasedOnStyles = spelling
TokenIgnores = (http[^\n]+)

With styles/spelling/spelling.yml:

extends: spelling
message: "Did you really mean '%s'?"
level: error

And file.yaml:

references:
  - https://docs.aws.amazon.com/workspaces/latest/adminguide/data-protection.html

When running vale file.yaml:

 file.yaml
 2:5   error  Did you really mean 'https'?    spelling.spelling
 2:51  error  Did you really mean             spelling.spelling
              'adminguide'?
 2:78  error  Did you really mean 'html'?     spelling.spelling

Expected that TokenIgnores = (http[^\n]+) would result in 0 errors as the URL would be ignored.

@jdkato
Copy link
Member

jdkato commented Feb 2, 2022

TokenIgnores and BlockIgnores only work for supported markup formats.

#383 discusses a few options for YAML (and other serialization formats).

@rachelrice
Copy link
Author

TokenIgnores and BlockIgnores only work for supported markup formats.

#383 discusses a few options for YAML (and other serialization formats).

Thanks @jdkato

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants