diff options
| author | Craig Jennings <c@cjennings.net> | 2026-05-10 13:42:11 -0500 |
|---|---|---|
| committer | Craig Jennings <c@cjennings.net> | 2026-05-10 13:42:11 -0500 |
| commit | ff07ee56927d368c733e368be23adef7ed24964b (patch) | |
| tree | c0b9c8ccc02d45282135f650c4b4941c80fdfdb7 /docs | |
| parent | db7b1dd313a0bcf20eed83942940d0935b703618 (diff) | |
| download | dotemacs-ff07ee56927d368c733e368be23adef7ed24964b.tar.gz dotemacs-ff07ee56927d368c733e368be23adef7ed24964b.zip | |
refactor(dirvish): extract cj/--html-file-p; match HTML case-insensitively
`cj/dirvish-open-html-in-eww' inlined a `string-match-p' against `\.html?\=' to decide whether to hand a file to eww. The check was case-sensitive, so `.HTML' fell through to the "Not an HTML file" message even though every browser treats it as HTML. Lift the predicate into `cj/--html-file-p' and bind `case-fold-search' to t so uppercase and mixed-case extensions match. The trailing-`\=' anchor stays so files like `html-thing.org' still don't match.
Seven Normal/Boundary/Error tests cover lowercase `.html', `.htm', uppercase `.HTML', mixed-case `.Html', embedded `html' (no match), non-html extensions (no match), and no-extension files (no match).
Diffstat (limited to 'docs')
0 files changed, 0 insertions, 0 deletions
