From 7c0b5f9906f456b05880f25c01f6a3a587ffc479 Mon Sep 17 00:00:00 2001 From: Rolfe Dlugy-Hegwer Date: Fri, 20 Oct 2023 09:35:28 -0400 Subject: [PATCH] Create a localization rule --- .vale/fixtures/RedHat/Localization/.vale.ini | 5 +++++ .vale/fixtures/RedHat/Localization/testinvalid.adoc | 1 + .vale/fixtures/RedHat/Localization/testvalid.adoc | 0 .vale/styles/RedHat/Localization.yml | 9 +++++++++ 4 files changed, 15 insertions(+) create mode 100644 .vale/fixtures/RedHat/Localization/.vale.ini create mode 100644 .vale/fixtures/RedHat/Localization/testinvalid.adoc create mode 100644 .vale/fixtures/RedHat/Localization/testvalid.adoc create mode 100644 .vale/styles/RedHat/Localization.yml diff --git a/.vale/fixtures/RedHat/Localization/.vale.ini b/.vale/fixtures/RedHat/Localization/.vale.ini new file mode 100644 index 000000000..7ceb3141a --- /dev/null +++ b/.vale/fixtures/RedHat/Localization/.vale.ini @@ -0,0 +1,5 @@ +; Vale configuration file to test the `Localization` rule +StylesPath = ../../../styles +MinAlertLevel = warning +[*.adoc] +RedHat.Localization = YES diff --git a/.vale/fixtures/RedHat/Localization/testinvalid.adoc b/.vale/fixtures/RedHat/Localization/testinvalid.adoc new file mode 100644 index 000000000..8d35e0188 --- /dev/null +++ b/.vale/fixtures/RedHat/Localization/testinvalid.adoc @@ -0,0 +1 @@ +should diff --git a/.vale/fixtures/RedHat/Localization/testvalid.adoc b/.vale/fixtures/RedHat/Localization/testvalid.adoc new file mode 100644 index 000000000..e69de29bb diff --git a/.vale/styles/RedHat/Localization.yml b/.vale/styles/RedHat/Localization.yml new file mode 100644 index 000000000..d416db34e --- /dev/null +++ b/.vale/styles/RedHat/Localization.yml @@ -0,0 +1,9 @@ +--- +extends: existence +ignorecase: true +level: warning +link: https://redhat-documentation.github.io/vale-at-red-hat/docs/main/reference-guide/TBD/ +message: "Avoid terms that are ambiguous and problematic in a localization context" +# source: https://github.com/redhat-documentation/vale-at-red-hat/issues/515 +tokens: + - should