diff --git a/.github/vale/styles/OpenSearch/LinksExplicit.yml b/.github/vale/styles/OpenSearch/LinksExplicit.yml new file mode 100644 index 0000000000..a734259a3a --- /dev/null +++ b/.github/vale/styles/OpenSearch/LinksExplicit.yml @@ -0,0 +1,8 @@ +extends: existence +message: "In links, use '{{site.url}}{{site.baseurl}}' instead of 'https://www.opensearch.org/docs/latest'." +level: error +nonword: true +scope: raw +tokens: + - '\]\(https:\/\/www.opensearch.org\/docs\/latest' + \ No newline at end of file diff --git a/.github/vale/tests/test-style-pos.md b/.github/vale/tests/test-style-pos.md index 1cf640f463..a8af5442d8 100644 --- a/.github/vale/tests/test-style-pos.md +++ b/.github/vale/tests/test-style-pos.md @@ -38,6 +38,8 @@ This sentence tests [links end slash]({{site.url}}{{site.baseurl}}/opensearch). This sentence tests [links mid slash]({{site.url}}{{site.baseurl}}opensearch). +This sentence tests [links explicit](https://www.opensearch.org/docs/latest/double-slash/). + This sentence tests log-in as a noun. To login, we test this as a verb. To test merge conflicts, remove tick marks in `<<<<<<< HEAD`. diff --git a/.vale.ini b/.vale.ini index 2fb470b9dc..ffd25e32e9 100644 --- a/.vale.ini +++ b/.vale.ini @@ -38,6 +38,7 @@ OpenSearch.LatinismsSubstitution = YES OpenSearch.LinksDoubleParentheses = YES OpenSearch.LinksDoubleSlash = YES OpenSearch.LinksEndSlash = YES +OpenSearch.LinksExplicit = YES OpenSearch.LinksMidSlash = YES OpenSearch.LoginNoun = YES OpenSearch.LoginVerb = YES