packages feed

acolyte-server-0.1.0.0: acolyte-server.cabal

cabal-version:   3.0
name:            acolyte-server
version:         0.1.0.0
synopsis:        HTTP server interpretation for acolyte
category:        Web
description:
  Interprets acolyte-core API types into a running HTTP
  server. Provides handler binding, request extraction, response
  encoding, routing, and the compile-time completeness check.
  .
  Produces a spire Service. Backend-agnostic: combine with spire-wai
  to run on warp, or any other adapter.

license:         BSD-3-Clause
license-file:    LICENSE
author:          Josh Burgess
maintainer:      Josh Burgess <joshburgess.webdev@gmail.com>
homepage:        https://github.com/joshburgess/acolyte
bug-reports:     https://github.com/joshburgess/acolyte/issues
build-type:      Simple

extra-doc-files:
  CHANGELOG.md

flag dev-tests
  description:
    Build dev-only test suites that shell out to @cabal exec ghc@.
    These rely on the in-place package database from @cabal build@
    in the source workspace and cannot run from an installed
    package, so they are off by default.
  default: False
  manual: True

library
  exposed-modules:
    Acolyte.Server
    Acolyte.Server.Extract
    Acolyte.Server.Response
    Acolyte.Server.Handler
    Acolyte.Server.Router
    Acolyte.Server.Wiring
    Acolyte.Server.Effects
    Acolyte.Server.Combine
    Acolyte.Server.CombineEffects
    Acolyte.Server.Validate
    Acolyte.Server.ToHandler
    Acolyte.Server.MkApi
    Acolyte.Server.Negotiate
    Acolyte.Server.Named
    Acolyte.Server.Streaming

  build-depends:
      base                    >= 4.20 && < 5
    , acolyte-core            >= 0.1  && < 0.2
    , spire                   >= 0.1  && < 0.2
    , http-core               >= 0.1  && < 0.2
    , aeson                   >= 2.1  && < 2.3
    , bytestring              >= 0.11 && < 0.13
    , text                    >= 2.0  && < 2.2
    , http-types              >= 0.12 && < 0.13
    , containers              >= 0.6  && < 0.8
    , case-insensitive        >= 1.2  && < 1.3

  hs-source-dirs: src
  default-language: GHC2024
  default-extensions:
    DataKinds
    GADTs
    TypeFamilies
    TypeOperators
    OverloadedStrings
    AllowAmbiguousTypes
    UndecidableInstances
    ConstraintKinds
    StandaloneKindSignatures
    MultiParamTypeClasses
    FunctionalDependencies
    FlexibleInstances
    FlexibleContexts
    ScopedTypeVariables
    StrictData

  ghc-options: -Wall -funbox-strict-fields

test-suite spec
  type: exitcode-stdio-1.0
  main-is: Main.hs
  hs-source-dirs: test
  default-language: GHC2024
  default-extensions:
    DataKinds
    GADTs
    TypeFamilies
    TypeOperators
    OverloadedStrings
    AllowAmbiguousTypes
    UndecidableInstances
    ConstraintKinds
    ScopedTypeVariables
    StrictData

  ghc-options: -Wall -rtsopts "-with-rtsopts=-K1K"

  build-depends:
      base                    >= 4.20 && < 5
    , acolyte-server          >= 0.1  && < 0.2
    , acolyte-core            >= 0.1  && < 0.2
    , spire                   >= 0.1  && < 0.2
    , http-core               >= 0.1  && < 0.2
    , aeson                   >= 2.1  && < 2.3
    , bytestring              >= 0.11 && < 0.13
    , text                    >= 2.0  && < 2.2
    , http-types              >= 0.12 && < 0.13
    , case-insensitive        >= 1.2  && < 1.3

test-suite properties
  type: exitcode-stdio-1.0
  main-is: Properties.hs
  hs-source-dirs: test
  default-language: GHC2024
  default-extensions:
    DataKinds
    OverloadedStrings
    StrictData
  ghc-options: -Wall
  build-depends:
      base                    >= 4.20 && < 5
    , acolyte-server          >= 0.1  && < 0.2
    , acolyte-core            >= 0.1  && < 0.2
    , http-core               >= 0.1  && < 0.2
    , hedgehog                >= 1.4  && < 1.8
    , aeson                   >= 2.1  && < 2.3
    , bytestring              >= 0.11 && < 0.13
    , text                    >= 2.0  && < 2.2
    , http-types              >= 0.12 && < 0.13

test-suite typeerrors
  type: exitcode-stdio-1.0
  main-is: TypeErrors.hs
  hs-source-dirs: test
  default-language: GHC2024
  ghc-options: -Wall

  if !flag(dev-tests)
    buildable: False

  build-depends:
      base                    >= 4.20 && < 5
    , process                 >= 1.6  && < 1.8
    , directory               >= 1.3  && < 1.4

source-repository head
  type:     git
  location: https://github.com/joshburgess/acolyte.git