packages feed

aur 7.0.3 → 7.0.4

raw patch · 4 files changed

+11/−3 lines, 4 filesPVP ok

version bump matches the API change (PVP)

API changes (from Hackage documentation)

Files

CHANGELOG.md view
@@ -1,5 +1,9 @@ # Changelog +## 7.0.4 (2020-09-11)++- Escape `+` that can occasionally appear in package names.+ ## 7.0.3 (2020-05-27)  - Bumped `http-client` bounds.
aur.cabal view
@@ -1,6 +1,6 @@ cabal-version:      2.2 name:               aur-version:            7.0.3+version:            7.0.4 synopsis:           Access metadata from the Arch Linux User Repository. description:   Access package information from Arch Linux's AUR via its RPC interface. The
lib/Linux/Arch/Aur.hs view
@@ -123,7 +123,11 @@ info m ps = work m url   where     url = "https://aur.archlinux.org/rpc?v=5&type=info&" <> as-    as = T.unpack . T.intercalate "&" $ map ("arg%5B%5D=" <>) ps+    as = T.unpack . T.intercalate "&" $ map (\p -> "arg%5B%5D=" <> T.concatMap escape p) ps++escape :: Char -> Text+escape '+' = "%2B"+escape c   = T.singleton c  -- | Perform a @search@ call on a package name or description text. -- Will fail with a `Left` if there was a connection/decoding error.
tests/Test.hs view
@@ -18,7 +18,7 @@   ]  infoTest :: Manager -> Assertion-infoTest m = info m ["aura", "aura-bin"] >>= \x -> (length <$> x) @?= Right 2+infoTest m = info m ["aura", "aura-bin", "libc++"] >>= \x -> (length <$> x) @?= Right 3  infoTest' :: Manager -> Assertion infoTest' m = info m ["aura1234567"] >>= \x -> (null <$> x) @?= Right True