From 02eda42ce66c2a2b8900036586892ad07eaf7bf0 Mon Sep 17 00:00:00 2001 From: Jan Loewe Date: Mon, 17 Apr 2023 12:25:22 +0200 Subject: [PATCH] fix(regex): match windows line endings aswell --- src/main.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main.rs b/src/main.rs index 59a8299..b4ac8f8 100644 --- a/src/main.rs +++ b/src/main.rs @@ -64,7 +64,7 @@ fn handle_supports(pre: &dyn Preprocessor, sub_args: &ArgMatches) -> ! { } lazy_static! { - static ref HEADER_RE: Regex = Regex::new(r"(?P
---\n((.+\n)+)---)").unwrap(); + static ref HEADER_RE: Regex = Regex::new(r"(?P
---\r?\n((.+\r?\n)+)---)").unwrap(); } /// A pre-processor that removes header between ---