Conversation
There was a problem hiding this comment.
Pull request overview
This PR fixes regex patterns in the typos configuration file to properly handle spellchecker ignore directives. The main fix corrects the HTML comment pattern structure, changing it from a single-comment pattern to properly match separate opening and closing comment tags.
Key Changes
- Updated regex patterns to use
[\\s\\S]*?instead of.*?\\n\\s*for more flexible matching - Fixed HTML comment pattern to correctly match separate opening (
<!-- spellchecker:off -->) and closing (<!-- spellchecker:on -->) comments - Added trailing comma for consistency in the configuration array
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| [default] | ||
| locale = 'en-us' | ||
| extend-ignore-re = [ | ||
| "(?s)(#|//)\\s*spellchecker:off.*?\\n\\s*(#|//)\\s*spellchecker:on", | ||
| "(?s)<!--\\s*spellchecker:off.*?\\n\\s*spellchecker:on\\s*-->", | ||
| "(?s)(#|//)\\s*spellchecker:off[\\s\\S]*?(#|//)\\s*spellchecker:on", | ||
| "(?s)<!--\\s*spellchecker:off\\s*-->[\\s\\S]*?<!--\\s*spellchecker:on\\s*-->", | ||
| "(?Rm)^.*#\\s*spellchecker:disable-line$", | ||
| "(?m)^.*<!--\\s*spellchecker:disable-line\\s*-->\\n.*$" | ||
| "(?m)^.*<!--\\s*spellchecker:disable-line\\s*-->\\n.*$", | ||
| ] | ||
|
|
||
| [files] |
There was a problem hiding this comment.
This is over kill let's remove this whole typo.toml. Not that hard to have a aspell checker in the editor itself and considering a lot of docs will be llm driven/reviewed there's very little risk to introduce typos
glebedel
left a comment
There was a problem hiding this comment.
we should remove the typos.toml / action checker
Pull request was closed
Summary by cubic
Updated typos.toml ignore regex to correctly skip sections wrapped with spellchecker:off/on in code and HTML comments, even across multiple lines. This reduces false positives from typos checks in disabled blocks.
Written for commit 0d410c8. Summary will update automatically on new commits.