Skip to content

Add Vale rule: #5160

Description

@aneta-petrova

Describe the style rule or guideline you would like to see automated

In https://github.com/theforeman/foreman-documentation/pull/5118/changes#r3720270567 and https://github.com/theforeman/foreman-documentation/pull/5150/changes, the ansible text string triggered a Vale error due to incorrect capitalization (ansible instead of Ansible as defined in https://github.com/theforeman/foreman-documentation/blob/master/.vale/styles/foreman-documentation/Capitalization.yml).

#5156 fixed this by ignoring cases where ansible is preceded or followed by - so that URL fragments are not reported. This is because URL links such as {ManagingConfigurationsAnsibleDocURL}enabling-the-ansible-plugin are expected to contain lowercase ansible.

However, a more systematic way to prevent these false errors would be to ensure that Vale ignores URLs that start with attributes such as {GuideNameDocURL}, just like it already ignores text strings in backticks, URLs that start with https://, etc.

Provide 2 examples of positive test cases and 2 examples of negative test cases

For example, Vale should report these instances:

  • ansible in free text

For example, Vale should not report these instances:

  • ansible in strings that start with {GuideNameDocURL} such as {ManagingConfigurationsAnsibleDocURL}enabling-the-ansible-plugin

Optional: Proposal for how to implement the rule (regular expression, Tengo script, etc.)

[x] I have checked the RedHat style package to make sure a rule like this does not exist there.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    Red Hat Jira

    None yet

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions