summoner-1.2.0: Tool for scaffolding completely configured production Haskell projects.

Safe HaskellNone
LanguageHaskell2010

Summoner.Config

Description

Summoner configurations.

Synopsis

Documentation

data ConfigP (p :: Phase) Source #

Potentially incomplete configuration.

Instances
Semigroup PartialConfig Source # 
Instance details

Defined in Summoner.Config

Monoid PartialConfig Source # 
Instance details

Defined in Summoner.Config

(Eq (p :- Text), Eq (p :- LicenseName), Eq (p :- [GhcVer])) => Eq (ConfigP p) Source # 
Instance details

Defined in Summoner.Config

Methods

(==) :: ConfigP p -> ConfigP p -> Bool #

(/=) :: ConfigP p -> ConfigP p -> Bool #

(Show (p :- Text), Show (p :- LicenseName), Show (p :- [GhcVer])) => Show (ConfigP p) Source # 
Instance details

Defined in Summoner.Config

Methods

showsPrec :: Int -> ConfigP p -> ShowS #

show :: ConfigP p -> String #

showList :: [ConfigP p] -> ShowS #

Generic (ConfigP p) Source # 
Instance details

Defined in Summoner.Config

Associated Types

type Rep (ConfigP p) :: Type -> Type #

Methods

from :: ConfigP p -> Rep (ConfigP p) x #

to :: Rep (ConfigP p) x -> ConfigP p #

(GSemigroup (p :- Text), GSemigroup (p :- LicenseName), GSemigroup (p :- [GhcVer])) => GSemigroup (ConfigP p) Source # 
Instance details

Defined in Summoner.Config

Methods

gsappend :: ConfigP p -> ConfigP p -> ConfigP p #

gstimes :: Integral b => b -> ConfigP p -> ConfigP p #

gsconcat :: NonEmpty (ConfigP p) -> ConfigP p #

(GMonoid (p :- Text), GMonoid (p :- LicenseName), GMonoid (p :- [GhcVer])) => GMonoid (ConfigP p) Source # 
Instance details

Defined in Summoner.Config

Methods

gmempty :: ConfigP p #

gmappend :: ConfigP p -> ConfigP p -> ConfigP p #

gmconcat :: [ConfigP p] -> ConfigP p #

type Rep (ConfigP p) Source # 
Instance details

Defined in Summoner.Config

type Rep (ConfigP p)

type PartialConfig = ConfigP Partial Source #

Incomplete configurations.

type Config = ConfigP Final Source #

Complete configurations.

configT :: TomlCodec PartialConfig Source #

Identifies how to read ConfigP data from the .toml file.

defaultConfig :: PartialConfig Source #

Default ConfigP configurations.

finalise :: PartialConfig -> Validation [Text] Config Source #

Make sure that all the required configurations options were specified.

loadFileConfig :: MonadIO m => FilePath -> m PartialConfig Source #

Read configuration from the given file and return it in data type.