rio-0.1.14.1: A standard library for Haskell

Safe HaskellNone
LanguageHaskell2010

RIO.Prelude.Simple

Description

Provide a SimpleApp datatype, for providing a basic App-like environment with common functionality built in. This is intended to make it easier to, e.g., use rio's logging and process code from within short scripts.

Since: 0.1.3.0

Synopsis

Documentation

data SimpleApp Source #

A simple, non-customizable environment type for RIO, which provides common functionality. If it's insufficient for your needs, define your own, custom App data type.

Since: 0.1.3.0

mkSimpleApp :: MonadIO m => LogFunc -> Maybe ProcessContext -> m SimpleApp Source #

Constructor for SimpleApp. In case when ProcessContext is not supplied mkDefaultProcessContext will be used to create it.

Since: 0.1.14.0

runSimpleApp :: MonadIO m => RIO SimpleApp a -> m a Source #

Run with a default configured SimpleApp, consisting of:

  • Logging to stderr
  • If the RIO_VERBOSE environment variable is set, turns on verbose logging
  • Default process context

Since: 0.1.3.0