cabal-version: >= 1.10

name:                readability
version:             0.1.0.0
synopsis:            Extracts text of main article from HTML document
description:         Give @readability@ an HTML document and it will detect and extract text of the article while removing everything unnecessary like menus, advertisements or sidebars. It is more or less reimplementation of [python-readability](https://github.com/buriy/python-readability).
homepage:            https://sr.ht/~geyaeb/haskell-readability
bug-reports:         https://todo.sr.ht/~geyaeb/haskell-readability
license:             BSD3
license-file:        LICENSE
author:              G. Eyaeb
maintainer:          geyaeb@protonmail.com
copyright:           2020 G. Eyaeb
category:            Text, HTML
build-type:          Simple
extra-source-files:  CHANGELOG.md, README.md

source-repository head
  type:              mercurial
  location:          https://hg.sr.ht/~geyaeb/haskell-readability

library
  exposed-modules:
      Readability
      Readability.Clean
      Readability.Helper
      Readability.Internal
      Readability.Metrics
      Readability.Title
      Readability.Types
  hs-source-dirs:
      src
  ghc-options:
     -Wall
     -Wincomplete-uni-patterns
     -Wincomplete-record-updates
     -Wcompat
     -Widentities
     -Wredundant-constraints
     -fhide-source-paths
     -Wmissing-export-lists
     -Wpartial-fields
  build-depends:
      base >=4.7 && <5
    , bytestring == 0.10.*
    , containers == 0.6.*
    , html-conduit == 1.3.*
    , text == 1.2.*
    , xml-conduit >=1.7 && <2
  default-language:
      Haskell2010

executable readability
  main-is: Main.hs
  hs-source-dirs:
      app
  ghc-options:
     -threaded
     -rtsopts
     -with-rtsopts=-N
     -Wall
  build-depends:
      base >=4.7 && <5
    , aeson >= 1.4 && < 1.6
    , http-conduit == 2.3.*
    , optparse-applicative == 0.15.*
    , readability
    , text == 1.2.*
    , xml-conduit >=1.7 && <2
  default-language:
      Haskell2010