mirror of
https://github.com/cfal/shoes.git
synced 2026-11-06 16:14:11 +00:00
* feat(config): add conditions while preserving mask rules Accept conditions alongside the existing masks and mask spellings, rejecting conflicting matching fields and flat-source combinations. Normalize all forms into the existing predicate engine. Add explicit masks leaves for composed expressions and source groups. Keep simple address exports compact and serialize richer rules under conditions. Cover round-trips, nested source discovery, controller payloads, warning-free compatibility, and routing across accepted and rejected reloads. * docs(routing): explain conditions and compatible mask syntax Document expression composition, conflicting fields, source shorthand, and canonical serialization in English and Chinese. Record the controller diagnostic shape in the changelog. Add a complete conditions example, validate it through the native configuration pipeline, and show conditions in the rule-source example. * fix(config): clarify invalid rule conditions diagnostics Name the mutually exclusive matching fields explicitly, including legacy aliases, instead of reporting an unwritten duplicate conditions key. Explain that nested masks leaves accept only strings or nonempty string lists, with regression tests for JSON/YAML conflicts and invalid leaf shapes. * refactor(tests): simplify rule conditions coverage Stage all spelling and format variants before checking their shared canonical form. Restore that form once while preserving per-variant compilation and the complete decision matrix. Remove conflict inputs already covered by stronger diagnostic assertions, clarify controller payload names, and validate all five rule forms in one fixture per CLI mode. * fix(rules): correct source-group predicate guidance Recommend the rule_source_group predicate without a masks wrapper so the rename hint works in nested expressions and source groups. Cover the suggested syntax and diagnostic in regression tests. Update both documentation locales to describe source-group references under conditions or masks, including boolean composition.