Expand description
Per-file no_reverse opt-out for the template reverse-merge.
[preprocessor.template] no_reverse = ["pattern", ...] lets a user
exclude specific template sources from dodot transform check’s
reverse-merge engine and from the clean filter’s slow path. Patterns
are globs, matched against the source file’s filename component
(so *.gen.tmpl matches app/foo.gen.tmpl, and a fully-spelled
complex-config.toml.tmpl matches anywhere in the tree).
The matching itself is dumb (no path walking, no recursion) — this module exists mostly to localise the rule and keep the two callers (transform check, template clean) consistent.
Functions§
- is_
no_ reverse - Returns true iff
source_path’s filename matches any of the glob patterns inpatterns. Patterns that fail to compile as globs are silently ignored (config validation upstream is the place to surface user error; from the engine’s point of view a bad pattern means “matches nothing”).