A Rust preprocessor for [mdBook](https://github.com/rust-lang/mdBook), replacing regular expression patterns with specified strings. Regex syntax is based on the [Regex](https://crates.io/crates/regex) Rust crate. ## Usage Install the crate ``` cargo install mdbook-regex ``` Specify the patterns and string replacement in a `.json` file ```json [ { "pattern" : "Your Pattern", "template" : "Your Template" } ] ``` Add the preprocessor to your `book.toml` file, and specify the path of the `.json` patterns file ```toml [preprocessor.regex] patterns = "path/to/patterns.json" ``` ## Example The following pattern ```json [ { "pattern" : "``collapse:(?P