packages feed

wai-middleware-static 0.7.0.0 → 0.7.0.1

raw patch · 3 files changed

+21/−24 lines, 3 filesdep −unixPVP ok

version bump matches the API change (PVP)

Dependencies removed: unix

API changes (from Hackage documentation)

Files

Network/Wai/Middleware/Static.hs view
@@ -33,11 +33,10 @@ import Network.HTTP.Types (status200, status304) import Network.HTTP.Types.Header (RequestHeaders) import Network.Wai-import System.Directory (doesFileExist)+import System.Directory (doesFileExist, getModificationTime) #if !(MIN_VERSION_time(1,5,0)) import System.Locale #endif-import System.Posix.Files import qualified Crypto.Hash.SHA1 as SHA1 import qualified Data.ByteString as B import qualified Data.ByteString as BS@@ -253,7 +252,7 @@  computeFileMeta :: FilePath -> IO FileMeta computeFileMeta fp =-    do mtime <- getModTime fp+    do mtime <- getModificationTime fp        ct <- BSL.readFile fp        return $ FileMeta                 { fm_lastModified =@@ -261,11 +260,6 @@                 , fm_etag = B16.encode (SHA1.hashlazy ct)                 , fm_fileName = fp                 }--getModTime :: FilePath -> IO UTCTime-getModTime fullFilePath =-    do stat <- getFileStatus fullFilePath-       return $ (\t -> posixSecondsToUTCTime (realToFrac t :: POSIXTime)) $ modificationTime stat  type Ascii = B.ByteString 
changelog.md view
@@ -1,3 +1,7 @@+## 0.7.0.1+* Fixed Windows build (by replacing `unix` dependency with equivalent `directory`+  function)+ ## 0.7.0.0 * Implement caching [agrafix] * Include mp4 and ogv mime_types [DrBoolean]
wai-middleware-static.cabal view
@@ -1,5 +1,5 @@ Name:                wai-middleware-static-Version:             0.7.0.0+Version:             0.7.0.1 Synopsis:            WAI middleware that serves requests to static files. Homepage:            https://github.com/scotty-web/wai-middleware-static Bug-reports:         https://github.com/scotty-web/wai-middleware-static/issues@@ -24,21 +24,20 @@   Exposed-modules:     Network.Wai.Middleware.Static   default-language:    Haskell2010   Build-depends:-                       base             >= 4.6.0.1  && < 5,-                       base16-bytestring >= 0.1 && < 0.2,-                       bytestring       >= 0.10.0.2 && < 0.11,-                       containers       >= 0.5.0.0  && < 0.6,-                       cryptohash       >= 0.11     && < 0.12,-                       directory        >= 1.2.0.1  && < 1.3,-                       expiring-cache-map >= 0.0.5  && < 0.1,-                       filepath         >= 1.3.0.1  && < 1.5,-                       http-types       >= 0.8.2    && < 0.9,-                       mtl              >= 2.1.2    && < 2.3,-                       old-locale       >= 1.0      && < 1.1,-                       text             >= 0.11.3.1 && < 1.3,-                       time             >= 1.4      && < 1.6,-                       unix             >= 2.7      && < 2.8,-                       wai              >= 3.0.0    && < 3.1+                       base               >= 4.6.0.1  && < 5,+                       base16-bytestring  >= 0.1      && < 0.2,+                       bytestring         >= 0.10.0.2 && < 0.11,+                       containers         >= 0.5.0.0  && < 0.6,+                       cryptohash         >= 0.11     && < 0.12,+                       directory          >= 1.2.0.1  && < 1.3,+                       expiring-cache-map >= 0.0.5    && < 0.1,+                       filepath           >= 1.3.0.1  && < 1.5,+                       http-types         >= 0.8.2    && < 0.9,+                       mtl                >= 2.1.2    && < 2.3,+                       old-locale         >= 1.0      && < 1.1,+                       text               >= 0.11.3.1 && < 1.3,+                       time               >= 1.4      && < 1.6,+                       wai                >= 3.0.0    && < 3.1    GHC-options: -Wall -fno-warn-orphans