gdritter repos frontit / 5d4cb39
Actually do relative paths right Getty Ritter 7 years ago
1 changed file(s) with 2 addition(s) and 2 deletion(s). Collapse all Expand all
1616 import qualified System.Directory as Dir
1717 import qualified System.Environment as Env
1818 import qualified System.Exit as Exit
19 import System.FilePath ((</>))
19 import System.FilePath ((</>), makeRelative)
2020 import qualified Text.Pandoc as Pandoc
2121
2222 data FrontitOpts = FrontitOpts
7979
8080 fetchPage :: FrontitConf -> FilePath -> IO Result
8181 fetchPage conf path = do
82 let localPath = fcData conf </> path
82 let localPath = fcData conf </> (makeRelative "/" path)
8383 exists <- Dir.doesFileExist localPath
8484 if not exists
8585 then return NotFound