From ee73be2822adeea897311eb8caac93291845ff02 Mon Sep 17 00:00:00 2001 From: stuebinm Date: Thu, 16 Dec 2021 22:22:56 +0100 Subject: fix a bug when writing things out (it didn't check if directories to save maps in actually existed) --- lib/WriteRepo.hs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/WriteRepo.hs b/lib/WriteRepo.hs index 7e3e5f2..c1a3f78 100644 --- a/lib/WriteRepo.hs +++ b/lib/WriteRepo.hs @@ -36,9 +36,9 @@ writeAdjustedRepository config inPath outPath result createDirectoryIfMissing True outPath -- write out all maps - mapM_ - (\(path,out) -> encodeFile (outPath path) $ mapresultAdjusted out) - (toList $ dirresultMaps result) + forM_ (toList $ dirresultMaps result) $ \(path,out) -> do + createDirectoryIfMissing True (takeDirectory (outPath path)) + encodeFile (outPath path) $ mapresultAdjusted out unless (configDontCopyAssets config) $ do -- collect asset dependencies of maps -- cgit v1.2.3