From 3d7d3bf5a54eed34bb09729defebf261cc7c3683 Mon Sep 17 00:00:00 2001 From: Ben Bridle Date: Fri, 17 Oct 2025 10:52:15 +1300 Subject: Add a html.redirect.head key to insert text into HTML redirects This is needed so that I can include the analytics script in all of my redirect pages. --- src/main.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/main.rs') diff --git a/src/main.rs b/src/main.rs index e52aa10..3ee0bc6 100644 --- a/src/main.rs +++ b/src/main.rs @@ -130,12 +130,12 @@ fn main() { if export_html { if !path.contains("://") { if let Some(path) = website.has_page(redirect, &path, "html") { - write_file(&generate_html_redirect(&path), &destination, "html", redirect.last_modified); + write_file(&generate_html_redirect(&path, &website), &destination, "html", redirect.last_modified); } else { warn!("Redirect {:?} links to nonexistent page {path:?}", redirect.name); } } else { - write_file(&generate_html_redirect(&path), &destination, "html", redirect.last_modified); + write_file(&generate_html_redirect(&path, &website), &destination, "html", redirect.last_modified); } } } -- cgit v1.2.3-70-g09d2