Skip to content

v1.2.3

Latest

Choose a tag to compare

@saberzero1 saberzero1 released this 22 Sep 20:53
v1.2.3
8167cae

Fixes a regression introduced in v1.2.2. No action is needed to pick it up if you reference the action as @v1.

Fixed

Valid Markdown images were no longer counted in the README check

v1.2.2 rewrote the Markdown image pattern so it could not backtrack, by excluding each opening delimiter from its own character class. That kept the pattern linear, but it also stopped it recognising valid Markdown:

![diagram](images/build_(dark).png)
![label with [brackets]](image.png)

A balanced pair of parentheses in the destination is legal Markdown and appears in real filenames. The first form was previously matched, if truncated at the inner ); the second was already missed before v1.2.2.

An unrecognised image is neither counted toward the image total nor stripped from the prose total, so both halves of the readme-screenshots-only heuristic moved in the same wrong direction and a README of screenshots could avoid the finding.

A regular expression cannot match balanced delimiters at all, and the narrow character classes needed to keep one linear are exactly what dropped the valid syntax. The check now builds the matching [/] and (/) positions in two passes and reads them in a third, which stays linear while handling nesting and backslash escapes that the original pattern did not.

Images nested inside links, the common badge form [![badge](image)](link), are still counted as before. A README consisting of 400,000 ![ sequences scans in about 96 ms.

Full Changelog: v1.2.2...v1.2.3