git.iko.soy/typeable/pandoc
on master help sign in
Remove directory compat

directory 1.1 depends on base 4.5 (ghc 7.4) which we are no longer supporting. So we don't have to use a compatibility layer for it.

commitf72e3b58e8edd9d81c982ec9e9c54fbc0ba94dcd authorJesse Rosenthal <jrosenthal@jhu.edu> dateThu 1 Sep 2016, 06:28 (10 years ago) parent7f676b5
3 files changed+2−24
pandoc.cabal+1−2 src/Text/Pandoc/Compat/Directory.hs−21 src/Text/Pandoc/Readers/Txt2Tags.hs+1−1
pandoc.cabal+1−2
@@ -416,7 +416,6 @@ Library
416416 Text.Pandoc.Highlighting,
417417 Text.Pandoc.Compat.Time,
418418 Text.Pandoc.Compat.TagSoupEntity,
419− Text.Pandoc.Compat.Directory,
420419 Paths_pandoc
421420
422421 Buildable: True
@@ -425,7 +424,7 @@ Executable pandoc
425424 Build-Depends: pandoc,
426425 pandoc-types >= 1.16 && < 1.17,
427426 base >= 4.2 && <5,
428− directory >= 1 && < 1.3,
427+ directory >= 1.2 && < 1.3,
429428 filepath >= 1.1 && < 1.5,
430429 text >= 0.11 && < 1.3,
431430 bytestring >= 0.9 && < 0.11,
src/Text/Pandoc/Compat/Directory.hsdeleted−21
@@ -1,21 +0,0 @@
1−{-# LANGUAGE CPP #-}
2−module Text.Pandoc.Compat.Directory ( getModificationTime )
3− where
4−
5−#if MIN_VERSION_directory(1,2,0)
6−import System.Directory
7−
8−
9−#else
10−import qualified System.Directory as S
11−import Data.Time.Clock (UTCTime)
12−import Data.Time.Clock.POSIX
13−import System.Time
14−
15−getModificationTime :: FilePath -> IO UTCTime
16−getModificationTime fp = convert `fmap` S.getModificationTime fp
17− where
18− convert (TOD x _) = posixSecondsToUTCTime (realToFrac x)
19−
20−#endif
21−
src/Text/Pandoc/Readers/Txt2Tags.hs+1−1
@@ -49,7 +49,7 @@ import Control.Monad.Reader (Reader, runReader, asks)
4949import Text.Pandoc.Error
5050
5151import Data.Time.LocalTime (getZonedTime)
52−import Text.Pandoc.Compat.Directory(getModificationTime)
52+import System.Directory(getModificationTime)
5353import Data.Time.Format (formatTime)
5454import Text.Pandoc.Compat.Time (defaultTimeLocale)
5555import System.IO.Error (catchIOError)