name:                tomland
version:             0.3.1
synopsis:            TOML parser
description:         See README.md for details.
homepage:            https://github.com/kowainik/tomland
bug-reports:         https://github.com/kowainik/tomland/issues
license:             MPL-2.0
license-file:        LICENSE
author:              Kowainik
maintainer:          xrom.xkov@gmail.com
copyright:           2018 Kowainik
category:            Data, Text, Configuration, TOML
build-type:          Simple
extra-doc-files:     README.md
                   , CHANGELOG.md
cabal-version:       1.24
tested-with:         GHC == 8.4.3
                   , GHC == 8.2.2
                   , GHC == 8.0.2

library
  hs-source-dirs:      src

  exposed-modules:     Toml
                         Toml.Bi
                           Toml.Bi.Code
                           Toml.Bi.Combinators
                           Toml.Bi.Monad
                         Toml.Edsl
                         Toml.Parser
                         Toml.PrefixTree
                         Toml.Printer
                         Toml.Prism
                         Toml.Type
                           Toml.Type.AnyValue
                           Toml.Type.TOML
                           Toml.Type.UValue
                           Toml.Type.Value

  build-depends:       base >= 4.9 && < 5
                     , hashable
                     , megaparsec
                     , mtl
                     , parser-combinators
                     , text
                     , time
                     , transformers >= 0.5
                     , unordered-containers

  ghc-options:         -Wall
  default-language:    Haskell2010
  default-extensions:  DeriveGeneric
                       GeneralizedNewtypeDeriving
                       InstanceSigs
                       LambdaCase
                       OverloadedStrings
                       RecordWildCards
                       TypeApplications

executable play-tomland
  main-is:             Playground.hs
  build-depends:       base
                     , tomland
                     , text
                     , time
                     , unordered-containers

  hs-source-dirs:      examples
  default-language:    Haskell2010
  ghc-options:         -threaded -Wall
  default-extensions:  OverloadedStrings
                       RecordWildCards

test-suite tomland-test
  type:                exitcode-stdio-1.0
  hs-source-dirs:      test
  main-is:             Spec.hs

  other-modules:       Test.Toml.Gen
  other-modules:       Test.Toml.Property
                       Test.Toml.Parsing.Property
                       Test.Toml.Parsing.Unit
                       Test.Toml.PrefixTree.Property
                       Test.Toml.PrefixTree.Unit
                       Test.Toml.TOML.Property

  build-tool-depends:  tasty-discover:tasty-discover
  build-depends:       base
                     , tomland
                     , hedgehog
                     , hspec-megaparsec
                     , megaparsec
                     , tasty
                     , tasty-hedgehog
                     , tasty-hspec
                     , text
                     , time
                     , unordered-containers

  ghc-options:         -Wall -threaded -rtsopts -with-rtsopts=-N

  default-language:    Haskell2010
  default-extensions:  OverloadedStrings
                       RecordWildCards

source-repository head
  type:                git
  location:            https://github.com/kowainik/tomland.git