Skip to content

Create Vale rule from working regex: How to conditionally match "Internet" #817

Answered by jdkato
daobrien asked this question in Q&A
Discussion options

You must be logged in to vote
extends: existence
message: "'%s' should only be capitalized when starting a sentence."
level: error
nonword: true
scope:
  - heading
  - list
  - sentence
tokens:
  - (?<=\s)Internet(?! Service Provider| Protocol)

See also this Vale Studio session.

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@daobrien
Comment options

@jdkato
Comment options

Answer selected by daobrien
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants