dsh-mp-catalog-guard
Content-catalog guard for WeChat mini-programs: validates catalog.json so every activity price is an integer amountFen, every template renders prices through money(), required fields / duplicate copy / image paths are checked, and the result is an issue list plus a unified diff that can be applied with patch -p1. 29 rules over five groups (catalog shape, required fields and uniqueness, amounts, rendering, images). Three fixes are automatic (legacy yuan amount, string Fen, absolute image path) and preserve the file's own indent, EOL and trailing newline; everything else is reported with a hint instead of being guessed. Dry-run by default; apply re-checks the written file so the report describes what remains. One implementation serves a tool, a conversation panel and a CLI with exit codes 0/1/2. Zero runtime dependencies, no model call, no network.
Overview
Content-catalog guard for WeChat mini-programs: validates catalog.json so every activity price is an integer amountFen, every template renders prices through money(), required fields / duplicate copy / image paths are checked, and the result is an issue list plus a unified diff that can be applied with patch -p1. 29 rules over five groups (catalog shape, required fields and uniqueness, amounts, rendering, images). Three fixes are automatic (legacy yuan amount, string Fen, absolute image path) and preserve the file's own indent, EOL and trailing newline; everything else is reported with a hint instead of being guessed. Dry-run by default; apply re-checks the written file so the report describes what remains. One implementation serves a tool, a conversation panel and a CLI with exit codes 0/1/2. Zero runtime dependencies, no model call, no network.
Installation
Version compatibility
Compatibility is unconfirmed. Check the project documentation for supported versions.
Installation notes
- May run terminal commands