packages feed

acolyte-core-0.1.0.1: acolyte-core.cabal

cabal-version:   3.12
name:            acolyte-core
version:         0.1.0.1
synopsis:        Type-level API specification for acolyte
category:        Web
description:
  Pure type-level machinery for describing HTTP APIs as types.
  Endpoints, paths, methods, effects, session types, versioning,
  and content negotiation. No IO, no runtime beyond base.

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.Core
    Acolyte.Core.Method
    Acolyte.Core.Path
    Acolyte.Core.Endpoint
    Acolyte.Core.API
    Acolyte.Core.Effect
    Acolyte.Core.Wrapper
    Acolyte.Core.Session
    Acolyte.Core.Versioning
    Acolyte.Core.Negotiate

  build-depends:
    base >= 4.20 && < 5,
    text >= 2.0 && < 2.2

  hs-source-dirs: src
  default-language: GHC2024

  default-extensions:
    DataKinds
    GADTs
    PolyKinds
    TypeFamilies
    TypeOperators
    UndecidableInstances
    ConstraintKinds
    StandaloneKindSignatures
    NoStarIsType
    RoleAnnotations
    AllowAmbiguousTypes
    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
    PolyKinds
    TypeFamilies
    TypeOperators
    UndecidableInstances
    ConstraintKinds
    StandaloneKindSignatures
    NoStarIsType
    AllowAmbiguousTypes
    StrictData

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

  build-depends:
    base >= 4.20 && < 5,
    acolyte-core,
    text >= 2.0 && < 2.2

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