cabal-version:   3.0
name:            ${1:`template:project-name`}
version:         0.1.0.0
synopsis:        $1 is a Haskell prooject
description:     $1 is a super-duper cool Haskell project written by big and powerful Haskellers.
license:         GPL-3.0-only
license-file:    LICENSE
author:          `user-full-name` <`user-mail-address`>
maintainer:      `user-full-name` <`user-mail-address`>
category:        $4
build-type:      Simple
extra-doc-files: README.md

common common
  ghc-options: -Wno-typed-holes -fdefer-typed-holes -threaded -fdefer-type-errors

  default-extensions:
    BlockArguments
    DataKinds
    DuplicateRecordFields
    DeriveDataTypeable
    DeriveGeneric
    DeriveTraversable
    DerivingVia
    FlexibleContexts
    GADTs
    GeneralisedNewtypeDeriving
    LambdaCase
    MultiWayIf
    NoFieldSelectors
    OverloadedLabels
    OverloadedRecordDot
    OverloadedStrings
    PartialTypeSignatures
    PatternSynonyms
    StandaloneDeriving
    TypeApplications
    TypeFamilies

  default-language:   GHC2021

library
  import: common

  ghc-options: -fplugin=Effectful.Plugin

  -- cabal-fmt: expand src/ -Main
  exposed-modules:
`(mapconcat (lambda (x)
              (concat "    " x))
            template:modules
            "\n")`

  default-language: GHC2021

  build-depends:
    , base                       ^>=4.19.1.0
    , containers
    , hashable
    , mtl
    , transformers
    , lens
    , generic-lens
    , pretty-simple
    , text                       >=2.0       && <2.2
    , unordered-containers
    , effectful
    , effectful-plugin

  hs-source-dirs: src

-- executable $1
--   import: common
--   main-is: Main.hs
--   default-language: GHC2021
--   hs-source-dirs: app
--   build-depends:
--     , base   ^>=4.19.1.0
--     , $1
