@@ -1,5 +1,5 @@
11module Text.Hakyll.Util
2− ( touchDirectories,
2+ ( makeDirectories,
33 getRecursiveContents
44 ) where
55
@@ -7,10 +7,14 @@ import System.Directory
77import System.FilePath
88import Control.Monad
99
10−touchDirectories :: FilePath -> IO ()
11−touchDirectories path = createDirectoryIfMissing True dir
10+-- | Given a path to a file, try to make the path writable by making
11+-- all directories on the path.
12+makeDirectories :: FilePath -> IO ()
13+makeDirectories path = createDirectoryIfMissing True dir
1214 where dir = takeDirectory path
1315
16+-- | Get all contents of a directory. Note that files starting with a dot (.)
17+-- will be ignored.
1418getRecursiveContents :: FilePath -> IO [FilePath]
1519getRecursiveContents topdir = do
1620 names <- getDirectoryContents topdir