packages feed

email-validate 2.3 → 2.3.1

raw patch · 2 files changed

+64/−59 lines, 2 filesdep ~basedep ~doctestdep ~email-validatePVP ok

version bump matches the API change (PVP)

Dependency ranges changed: base, doctest, email-validate, hspec, template-haskell

API changes (from Hackage documentation)

Files

email-validate.cabal view
@@ -1,59 +1,60 @@-name: email-validate-version: 2.3-cabal-version: >=1.10-build-type: Simple-license: BSD3-license-file: LICENSE-maintainer: George Pollard <porges@porg.es>-stability: experimental-homepage: https://github.com/Porges/email-validate-hs-synopsis: Email address validation-description:-    Validating an email address string against RFC 5322-category: Text-author: George Pollard <porges@porg.es>--source-repository head-    type: git-    location: git://github.com/Porges/email-validate-hs.git--source-repository this-    type: git-    location: git://github.com/Porges/email-validate-hs.git-    tag: v2.3--library-    exposed-modules:-        Text.Email.QuasiQuotation-        Text.Email.Validate-        Text.Email.Parser-    build-depends:-        base >=4.4 && <5,-        attoparsec >=0.10.0 && <0.14,-        bytestring >=0.9 && <0.11,-        template-haskell >=2.11.1.0 && <2.12-    default-language: Haskell2010-    hs-source-dirs: src-    ghc-options: -Wall--test-suite Main-    type: exitcode-stdio-1.0-    main-is: Main.hs-    build-depends:-        email-validate ==2.3.*,-        base ==4.*,-        hspec >=2.4.3 && <2.5,-        QuickCheck >=2.4 && <2.11,-        bytestring >=0.9 && <0.11-    default-language: Haskell2010-    hs-source-dirs: tests-    ghc-options: -threaded-test-suite doctests-    type: exitcode-stdio-1.0-    main-is: doctests.hs-    build-depends:-        base >=4.9.1.0 && <4.10,-        doctest >=0.8 && <0.12-    default-language: Haskell2010-    hs-source-dirs: tests-    ghc-options: -threaded+name:           email-validate
+version:        2.3.1
+license:        BSD3
+license-file:   LICENSE
+author:         George Pollard <porges@porg.es>
+maintainer:     George Pollard <porges@porg.es>
+homepage:       https://github.com/Porges/email-validate-hs
+category:       Text
+synopsis:       Email address validation
+description:    Validating an email address string against RFC 5322
+build-type:     Simple
+stability:      experimental
+cabal-version:  >= 1.10
+
+source-repository head
+    type: git
+    location: git://github.com/Porges/email-validate-hs.git
+
+source-repository this
+    type: git
+    location: git://github.com/Porges/email-validate-hs.git
+    tag: v2.3.1
+
+library
+    build-depends:
+        base >= 4.4 && < 5,
+        attoparsec >= 0.10.0 && < 0.14,
+        bytestring >= 0.9 && < 0.11,
+        template-haskell >= 2.10.0.0 && < 2.13
+    default-language: Haskell2010
+    hs-source-dirs: src
+    ghc-options: -Wall
+    exposed-modules:
+        Text.Email.QuasiQuotation,
+        Text.Email.Validate,
+        Text.Email.Parser
+
+test-suite Main
+    type: exitcode-stdio-1.0
+    main-is: Main.hs
+    ghc-options: -threaded
+    hs-source-dirs: tests
+    default-language: Haskell2010
+    build-depends:
+        email-validate,
+        base >= 4 && < 5,
+        hspec >= 2.2.3 && < 2.5,
+        QuickCheck >= 2.4 && < 2.11,
+        bytestring >= 0.9 && < 0.11
+
+test-suite doctests
+    type: exitcode-stdio-1.0
+    ghc-options: -threaded
+    default-language: Haskell2010
+    hs-source-dirs: tests
+    main-is: doctests.hs
+    build-depends:
+        base >= 4 && < 5,
+        doctest >= 0.8 && < 0.13
+
src/Text/Email/Validate.hs view
@@ -26,6 +26,7 @@ 
 -- $setup
 -- This is required for all examples:
+--
 -- >>> :set -XOverloadedStrings
 
 -- | Smart constructor for an email address
@@ -36,6 +37,7 @@ --   where comments and whitespace have been removed.
 --
 -- Example:
+--
 -- >>> canonicalizeEmail "spaces. are. allowed@example.com"
 -- Just "spaces.are.allowed@example.com"
 canonicalizeEmail :: ByteString -> Maybe ByteString
@@ -50,8 +52,10 @@ --   an email address, use this.
 --
 -- Examples:
+--
 -- >>> validate "example@example.com"
 -- Right "example@example.com"
+--
 -- >>> validate "not.good"
 -- Left "at sign > @: not enough input"
 validate :: ByteString -> Either String EmailAddress