@iobroker/repochecker 5.22.15 → 5.22.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -0
- package/lib/M6000_Readme.js +4 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -56,6 +56,9 @@ GITHUB_TOKEN=ghp_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
|
|
|
56
56
|
Placeholder for the next version (at the beginning of the line):
|
|
57
57
|
### **WORK IN PROGRESS**
|
|
58
58
|
-->
|
|
59
|
+
### 5.22.16 (2026-10-13)
|
|
60
|
+
* (@mcm1957) Fixed false positive [E6025] when README.md contains `#` headings inside fenced code blocks.
|
|
61
|
+
|
|
59
62
|
### 5.22.15 (2026-10-12)
|
|
60
63
|
* (mcm1957) src-blockly added to source directories excluded from E9507 / E9506 (missing i18n files) check
|
|
61
64
|
|
package/lib/M6000_Readme.js
CHANGED
|
@@ -375,7 +375,10 @@ async function checkReadme(context) {
|
|
|
375
375
|
context.errors.push('[E6001] No README.md found');
|
|
376
376
|
} else {
|
|
377
377
|
context.checks.push('README.md found');
|
|
378
|
-
|
|
378
|
+
// Strip fenced code blocks (``` ... ```) before counting H1 headers to avoid false positives
|
|
379
|
+
// from lines like "# heading" inside code examples.
|
|
380
|
+
const dataWithoutCodeBlocks = data.replace(/^`{3,}[\s\S]*?^`{3,}/gm, '');
|
|
381
|
+
const h1Headers = [...dataWithoutCodeBlocks.matchAll(MARKDOWN_H1_REGEX)];
|
|
379
382
|
if (h1Headers.length !== 1) {
|
|
380
383
|
context.errors.push(
|
|
381
384
|
`[E6025] README.md must contain exactly one H1 heading, but found ${h1Headers.length}.`,
|
package/package.json
CHANGED