American English Spelling Rule

This rule enforces American English spelling conventions by identifying common British/International English word patterns and suggesting their American English equivalents. The rule helps maintain consistency in documentation by ensuring American spelling standards are followed, which is particularly important for organizations targeting a primarily US audience or following US-based style guides like Google's developer documentation style guide.

Examples:

The rule specifically checks for:

  1. Words ending in "-nise" or "-nised":

    • ❌ "organise" → ✓ "organize"
    • ❌ "standardised" → ✓ "standardized"
  2. Words ending in "-logue":

    • ❌ "catalogue" → ✓ "catalog"
    • ❌ "dialogue" → ✓ "dialog"

The rule is case-insensitive and will flag these patterns regardless of capitalization. When triggered, it provides a warning message indicating that American spelling should be used instead.

Rule Source

This rule comes from: https://github.com/jump-dev/JuMP.jl

Rule Definition

extends: existence
message: "In general, use American spelling instead of '%s'."
link: 'https://developers.google.com/style/spelling'
ignorecase: true
level: warning
tokens:
  - '(?:\w+)nised?'
  - '(?:\w+)logue'