Safe Haskell | None |
---|---|
Language | GHC2021 |
Synopsis
- data CoreConfigP (p :: ConfigPhase) = MkCoreConfigP {
- init :: ConfigPhaseMaybeF p Text
- timeout :: ConfigPhaseMaybeF p Timeout
- commonLogging :: TomlOptF p (CommonLoggingP p)
- commandLogging :: TomlOptF p (CommandLoggingP p)
- consoleLogging :: TomlOptF p (ConsoleLoggingP p)
- fileLogging :: ArgsOnlyDetF p (FileLoggingP p)
- notify :: ArgsOnlyDetF p (NotifyP p)
- type CoreConfigArgs = CoreConfigP 'ConfigPhaseArgs
- type CoreConfigToml = CoreConfigP 'ConfigPhaseToml
- type CoreConfigMerged = CoreConfigP 'ConfigPhaseMerged
- mergeCoreConfig :: (HasCallStack, MonadTerminal m) => CoreConfigArgs -> Maybe CoreConfigToml -> m CoreConfigMerged
- withCoreEnv :: (HasCallStack, MonadDBus m, MonadFileWriter m, MonadHandleWriter m, MonadPathReader m, MonadPathWriter m, MonadSTM m, MonadTerminal m, MonadThrow m) => CoreConfigMerged -> (CoreConfigEnv -> m a) -> m a
- defaultMerged :: CoreConfigMerged
Types
data CoreConfigP (p :: ConfigPhase) Source #
Holds core configuration data.
MkCoreConfigP | |
|
Instances
type CoreConfigArgs = CoreConfigP 'ConfigPhaseArgs Source #
type CoreConfigToml = CoreConfigP 'ConfigPhaseToml Source #
Functions
mergeCoreConfig :: (HasCallStack, MonadTerminal m) => CoreConfigArgs -> Maybe CoreConfigToml -> m CoreConfigMerged Source #
withCoreEnv :: (HasCallStack, MonadDBus m, MonadFileWriter m, MonadHandleWriter m, MonadPathReader m, MonadPathWriter m, MonadSTM m, MonadTerminal m, MonadThrow m) => CoreConfigMerged -> (CoreConfigEnv -> m a) -> m a Source #
Given a merged CoreConfig, constructs a ConfigEnv and calls the continuation.