From 15190962ba210342572b955b3caa14adffbaf811 Mon Sep 17 00:00:00 2001 From: cmal Date: Tue, 7 Aug 2018 12:14:59 +0200 Subject: [PATCH] Copy relevant assets in case of colocation for section --- components/site/src/lib.rs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/components/site/src/lib.rs b/components/site/src/lib.rs index dd351ef7..5d4236ac 100644 --- a/components/site/src/lib.rs +++ b/components/site/src/lib.rs @@ -837,6 +837,12 @@ impl Site { } } + // Copy any asset we found previously into the same directory as the index.html + for asset in §ion.assets { + let asset_path = asset.as_path(); + copy(&asset_path, &output_path.join(asset_path.file_name().unwrap()))?; + } + if render_pages { section .pages