diff --git a/src/main.rs b/src/main.rs index 4f8f656..5e24d27 100644 --- a/src/main.rs +++ b/src/main.rs @@ -28,9 +28,9 @@ fn main() { .trim() .to_string(); - let announcements = Regex::new(r"\n+") + let pretty_announcements = Regex::new("\\n+") .unwrap() - .replace_all(&announcements, "\n") + .replace_all(&announcements, "") .to_string(); let description = &format_description!("[weekday] [month repr:long] [day] [year]"); @@ -42,8 +42,10 @@ fn main() { return; } + // println!("{}", pretty_announcements); + Webhook::new(webhook) - .content(&format!("## {}:\n{}", date, announcements)) + .content(&format!("## {}:\n{}", date, pretty_announcements)) .send() .unwrap(); }