packages feed

hurl 2.1.0.0 → 2.1.0.1

raw patch · 5 files changed

+11/−11 lines, 5 filesPVP ok

version bump matches the API change (PVP)

API changes (from Hackage documentation)

Files

ChangeLog.md view
@@ -1,5 +1,12 @@ # Revision history for hurl +## 2.1.0.1 -- 2021-03-09+* Fixes a build failure.++## 2.1.0.0+* Added APIs for localizing MIMEtypes+* Crash fixes+ ## 2.0.0.0 -- 2021-01-07 * Fix several real & potential crashes * Expose APIs for querying localized labels for MIME types from the OS
Main.hs view
@@ -7,20 +7,13 @@ import Data.Maybe (catMaybes) -- Where to save files import System.Directory (getCurrentDirectory)-import Network.MIME.Info (mimeInfo)  main :: IO () main = do     urls <- getArgs-    print $ queryMIMEs urls     let urls' = catMaybes $ map parseURI urls     session <- newSession     dir <- getCurrentDirectory      res <- fetchURLs session ["*/*"] urls' $ saveDownload nullURI dir     putStrLn $ show res--queryMIMEs [] = []-queryMIMEs (mime:mimes)-    | ':' `notElem` mime && '/' `elem` mime = mimeInfo mime : queryMIMEs mimes-    | otherwise = queryMIMEs mimes
hurl.cabal view
@@ -10,7 +10,7 @@ -- PVP summary:      +-+------- breaking API changes --                   | | +----- non-breaking API additions --                   | | | +--- code changes with no API change-version:             2.1.0.0+version:             2.1.0.1  -- A short (one-line) description of the package. synopsis:            Haskell URL resolver
src/Network/URI/Cache.hs view
@@ -23,11 +23,11 @@ import Control.Monad (forM, void, when) import Text.Read (readMaybe) -strip = C.dropWhile isSpace -- FIXME Upgrade bytestring dependency for a real strip function.+stripBS = C.dropWhile isSpace -- FIXME Upgrade bytestring dependency for a real strip function.  httpCacheDirective :: Response b -> Strict.ByteString -> Maybe Strict.ByteString httpCacheDirective response key | Just header <- lookup hCacheControl $ responseHeaders response =-        let directives = Prelude.map strip $ C.split ',' header+        let directives = Prelude.map stripBS $ C.split ',' header         in if key `Prelude.elem` directives             then Just ""             else listToMaybe $ mapMaybe (C.stripPrefix $ C.snoc key '=') directives
src/Network/URI/Types.hs view
@@ -7,4 +7,4 @@     icon :: URI,     description :: String,     appId :: String -- internal-} deriving (Show)+}