summaryrefslogtreecommitdiff
path: root/src/Text/Hakyll/Util.hs
diff options
context:
space:
mode:
authorJasper Van der Jeugt <jaspervdj@gmail.com>2009-12-02 16:23:21 +0100
committerJasper Van der Jeugt <jaspervdj@gmail.com>2009-12-02 16:23:21 +0100
commit1db2e00bbb813795cf858f69c21fa6c6837091a0 (patch)
tree8346a7a1e266d87e2be2d83d3f42d1aafd8092f3 /src/Text/Hakyll/Util.hs
parentf716440837521c192eeccdb95f210ff8b917db13 (diff)
downloadhakyll-1db2e00bbb813795cf858f69c21fa6c6837091a0.tar.gz
Fixed some more issues.
Diffstat (limited to 'src/Text/Hakyll/Util.hs')
-rw-r--r--src/Text/Hakyll/Util.hs3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/Text/Hakyll/Util.hs b/src/Text/Hakyll/Util.hs
index 3f56a18..f5a9954 100644
--- a/src/Text/Hakyll/Util.hs
+++ b/src/Text/Hakyll/Util.hs
@@ -14,7 +14,7 @@ touchDirectories path = createDirectoryIfMissing True dir
getRecursiveContents :: FilePath -> IO [FilePath]
getRecursiveContents topdir = do
names <- getDirectoryContents topdir
- let properNames = filter (`notElem` [".", ".."]) names
+ let properNames = filter isProper names
paths <- forM properNames $ \name -> do
let path = topdir </> name
isDirectory <- doesDirectoryExist path
@@ -22,3 +22,4 @@ getRecursiveContents topdir = do
then getRecursiveContents path
else return [path]
return (concat paths)
+ where isProper = not . (== '.') . head