packages feed

djot-0.1.0.0: djot.cabal

cabal-version:      3.0
name:               djot
version:            0.1.0.0
synopsis:           Parser and renderer for djot light markup syntax.
description:        Djot (<https://djot.net>) is a light markup language.
                    This package provides a data structure to represent
                    djot documents, a very fast parser, and functions
                    to render a parsed document as HTML and as djot.
license:            MIT
license-file:       LICENSE
author:             John MacFarlane
maintainer:         jgm@berkeley.edu
copyright:          Copyright (C) 2024 John MacFarlane
category:           Text
build-type:         Simple
extra-doc-files:    CHANGELOG.md
extra-source-files: test/*.test
                    benchmark/m.dj

Library
    build-depends:    base >= 4.12 && < 5,
                      bytestring >= 0.11.3,
                      containers,
                      mtl,
                      text,
                      doclayout
    hs-source-dirs:   src
    default-language: Haskell2010
    exposed-modules:  Djot
                      Djot.AST
                      Djot.Parse
                      Djot.Options
                      Djot.Attributes
                      Djot.Inlines
                      Djot.Blocks
                      Djot.Html
                      Djot.Djot
    ghc-options: -Wall -O2

executable djoths
    main-is:          Main.hs
    build-depends:    base >= 4.12 && < 5,
                      djot,
                      bytestring,
                      containers,
                      text,
                      doclayout
    hs-source-dirs:   app
    default-language: Haskell2010
    ghc-options: -Wall -O2 -rtsopts -threaded

test-suite test-djot
  type: exitcode-stdio-1.0
  main-is: Main.hs
  hs-source-dirs: test
  ghc-options: -Wall -threaded -rtsopts -with-rtsopts=-K40K -with-rtsopts=-kc40K
  if impl(ghc >= 8.10)
    ghc-options:      -Wunused-packages
  build-depends:
      base >= 4.12 && <5
    , djot
    , text
    , bytestring
    , directory
    , filepath
    , doclayout
    , tasty
    , tasty-hunit
    , tasty-quickcheck
  default-language: Haskell2010

benchmark benchmark-djot
  type:            exitcode-stdio-1.0
  main-is:         Main.hs
  hs-source-dirs:  benchmark
  build-depends:
       djot
     , base >= 4.9 && < 5
     , bytestring
     , directory
     , filepath
     , doclayout
     , tasty-bench
  ghc-options: -O2 -threaded -rtsopts -with-rtsopts=-K10K -with-rtsopts=-kc10K
  if impl(ghc >= 8.10)
    ghc-options:      -Wunused-packages
  default-language: Haskell2010