on master help sign in
Static files now also make use of cache.
30deeb3Jasper Van der Jeugt
src/Text/Hakyll/Render.hs+2−3
@@ -72,9 +72,8 @@ renderChain templates renderable =
72-- | Mark a certain file as static, so it will just be copied when the site is
72-- | Mark a certain file as static, so it will just be copied when the site is
73-- generated.
73-- generated.
74static :: FilePath -> IO ()
74static :: FilePath -> IO ()
75−static source = do
75+static source = depends destination [source]
76− makeDirectories destination
76+ (makeDirectories destination >> copyFile source destination)
77− copyFile source destination
78 where destination = toDestination source
77 where destination = toDestination source
79
78
80-- | Mark a whole directory as static.
79-- | Mark a whole directory as static.