Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
41 changes: 21 additions & 20 deletions JuicyPixels-blurhash.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,10 @@ library
build-depends:
JuicyPixels >=3.2.8 && <3.4
, base >=4.7 && <5
, bytestring >=0.9 && <0.11
, containers >=0.4.2 && <0.7
, filepath >=1.4.1.1 && <1.5
, vector >=0.10 && <0.13
, bytestring >=0.11
, containers >=0.4.2 && <=0.7
, filepath >=1.4.1.1 && <=1.6
, vector >=0.10 && <=0.14
default-language: Haskell2010

executable JuicyPixels-blurhash-exe
Expand All @@ -65,11 +65,11 @@ executable JuicyPixels-blurhash-exe
JuicyPixels >=3.2.8 && <3.4
, JuicyPixels-blurhash
, base >=4.7 && <5
, bytestring >=0.9 && <0.11
, containers >=0.4.2 && <0.7
, filepath >=1.4.1.1 && <1.5
, bytestring >=0.11
, containers >=0.4.2 && <=0.7
, filepath >=1.4.1.1 && <=1.6
, optparse-applicative >=0.14.3 && <0.18
, vector >=0.10 && <0.13
, vector >=0.10 && <=0.14
default-language: Haskell2010

test-suite JuicyPixels-blurhash-doctests
Expand All @@ -85,11 +85,11 @@ test-suite JuicyPixels-blurhash-doctests
, JuicyPixels >=3.2.8 && <3.4
, JuicyPixels-blurhash
, base >=4.7 && <5
, bytestring >=0.9 && <0.11
, containers >=0.4.2 && <0.7
, doctest >=0.16.2 && <0.20
, filepath >=1.4.1.1 && <1.5
, vector >=0.10 && <0.13
, bytestring >=0.11
, containers >=0.4.2 && <=0.7
, doctest >=0.22
, filepath >=1.4.1.1 && <=1.6
, vector >=0.10 && <=0.14
default-language: Haskell2010

test-suite JuicyPixels-blurhash-test
Expand All @@ -102,14 +102,15 @@ test-suite JuicyPixels-blurhash-test
JuicyPixels >=3.2.8 && <3.4
, JuicyPixels-blurhash
, base >=4.7 && <5
, bytestring >=0.9 && <0.11
, containers >=0.4.2 && <0.7
, filepath >=1.4.1.1 && <1.5
, hedgehog >=1.0.2 && <1.2
, bytestring >=0.11
, containers >=0.4.2 && <=0.7
, filepath >=1.4.1.1 && <=1.6
, hedgehog >=1.4
, tasty >=1.2.3 && <1.5
, tasty-discover >=4.2.1 && <4.3
, tasty-hedgehog >=1.0.0.2 && <1.2
, tasty-hedgehog >=1.4
, tasty-hunit >=0.10.0.2 && <0.11
, vector >=0.10 && <0.13
, vector >=0.10 && <=0.14
build-tool-depends:
tasty-discover:tasty-discover >=4.2 && <4.3
default-language: Haskell2010
other-modules: Blurhash
13 changes: 12 additions & 1 deletion doctest/Main.hs
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,15 @@ import System.FilePath.Glob (glob)
import Test.DocTest (doctest)

main :: IO ()
main = glob "src/**/*.hs" >>= doctest
main = do
sources <- glob "src/**/*.hs"
doctest $
[ "-isrc"
, "-XTemplateHaskell"
, "-XCPP"
, "-package=JuicyPixels"
, "-package=bytestring"
, "-package=containers"
, "-package=vector"
, "-package=filepath"
] ++ sources
4 changes: 2 additions & 2 deletions package.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -62,10 +62,10 @@ tests:
- -with-rtsopts=-N
dependencies:
- JuicyPixels-blurhash
- hedgehog >= 1.0.2 && < 1.2
- hedgehog >= 1.4
- tasty >= 1.2.3 && < 1.5
- tasty-discover >= 4.2.1 && < 4.3
- tasty-hedgehog >= 1.0.0.2 && < 1.2
- tasty-hedgehog >=1.4
- tasty-hunit >= 0.10.0.2 && < 0.11
JuicyPixels-blurhash-doctests:
main: Main.hs
Expand Down
2 changes: 1 addition & 1 deletion src/Codec/Picture/Blurhash/Internal/Base83.hs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import Data.Foldable (foldlM)
import Data.Word (Word8)

import qualified Data.ByteString.Lazy as BS
import qualified Data.ByteString.Lazy.Builder as BS
import qualified Data.ByteString.Builder as BS
import qualified Data.Map as Map
import qualified Data.Vector as V

Expand Down
2 changes: 1 addition & 1 deletion src/Codec/Picture/Blurhash/Internal/DList.hs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ toDList l = \l' -> l ++ l'

-- | Convert a difference list to a list
dListToList :: DList a -> [a]
dListToList = ($[])
dListToList = ($ [])

-- | Append an item to the end of a difference list
dListSnoc :: DList a -> a -> DList a
Expand Down
2 changes: 1 addition & 1 deletion src/Codec/Picture/Blurhash/Internal/Encode.hs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import Data.Foldable (foldl')
import GHC.Generics (Generic)

import qualified Data.ByteString.Lazy as BS
import qualified Data.ByteString.Lazy.Builder as BS
import qualified Data.ByteString.Builder as BS
import Codec.Picture (DynamicImage, Image(..), PixelRGB8(..), PixelRGBF(..), convertRGB8, colorMap)
import Codec.Picture.Types (pixelFold, ColorConvertible(..)) -- ColorConvertible imported for haddocks

Expand Down