From 1caaf4edbd23c3dd805fbc519da6c2007f73d77a Mon Sep 17 00:00:00 2001 From: Miguel Date: Tue, 19 Feb 2019 17:16:35 +0100 Subject: fix paths --- src/WWWStaticusPlugins.hs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/WWWStaticusPlugins.hs b/src/WWWStaticusPlugins.hs index 6718977..fe509f3 100644 --- a/src/WWWStaticusPlugins.hs +++ b/src/WWWStaticusPlugins.hs @@ -80,8 +80,8 @@ staticusPluginInit = StaticusPlugin "init" id runIO c <- getDirList (par "path" m) t <- getDirList (par "dir_in" m) - let menutop= concat $ map (\x->"
  • =1 && brc!!0==x then " active" else "")++"\">"++x++"
  • ") (menu t) - let submenu= if isHome then "" else concat $ map (\x->"
  • "++cln x++"
  • ") (menu c) + let menutop= concat $ map (\x->"
  • =1 && brc!!0==x then " active" else "")++"\">"++x++"
  • ") (menu t) + let submenu= if isHome then "" else concat $ map (\x->"
  • "++cln x++"
  • ") (menu c) let breadcrumbs=concat $ map (\(x,d)->"
  • "++(if d==0 then "" else "")++cln x++(if d==0 then "" else "")++"
  • ") (zip ("home":brc) [brcl,brcl-1..]) md <- readFile $ par "path" m++"/"++"index.md" @@ -96,6 +96,8 @@ staticusPluginInit = StaticusPlugin "init" id runIO ]) m where outdir = par "dir_out" m ++ "/" ++ intercalate "/" brc + htmlroot_dir = htmlroot ++ "/" ++ intercalate "/" brc + htmlroot = par "html_root" m brc = remUnder $ splitOn "/" (drop (length (par "dir_in" m)) (par "path" m)) brcl = length brc remUnder = filter (not.null) . map (dropWhile(=='_').dropWhile(/='_')) -- cgit v1.2.3