monad-logger-prefix: Add prefixes to your monad-logger output

[ library, system ] [ Propose Tags ]

See README.md


[Skip to Readme]
Versions [faq] 0.1.0, 0.1.1, 0.1.2, 0.1.3, 0.1.4, 0.1.5, 0.1.6, 0.1.7, 0.1.8, 0.1.9, 0.1.10, 0.1.11
Change log CHANGELOG.md
Dependencies base (==4.8.*), exceptions, monad-control, monad-logger, mtl, text, transformers, transformers-base [details]
License LicenseRef-Apache
Copyright 2016 Seller Labs
Author
Maintainer Matthew Parsons
Revised Revision 1 made by parsonsmatt at Wed Jun 29 20:32:06 UTC 2016
Category System
Home page https://github.com/sellerlabs/monad-logger-prefix#readme
Bug tracker https://github.com/sellerlabs/monad-logger-prefix/issues
Source repo head: git clone https://github.com/sellerlabs/monad-logger-prefix
Uploaded by parsonsmatt at Wed Jun 29 20:26:42 UTC 2016
Distributions LTSHaskell:0.1.11, NixOS:0.1.11, Stackage:0.1.11
Downloads 2496 total (208 in the last 30 days)
Rating (no votes yet) [estimated by rule of succession]
Your Rating
  • λ
  • λ
  • λ
Status Hackage Matrix CI
Docs not available [build log]
All reported builds failed as of 2016-11-23 [all 2 reports]

Modules

  • Control
    • Monad
      • Logger
        • Control.Monad.Logger.Prefix

Downloads

Note: This package has metadata revisions in the cabal description newer than included in the tarball. To unpack the package including the revisions, use 'cabal get'.

Maintainer's Corner

For package maintainers and hackage trustees


Readme for monad-logger-prefix-0.1.0

[back to package description]

monad-logger-prefix

This package provides an easy way to add prefixes to any MonadLogger. Here's a brief example:

{-# LANGUAGE TemplateHaskell #-}

import Control.Monad.Logger
import Control.Monad.Logger.Prefix

main :: IO ()
main = runStdoutLoggingT $ do
    $(logDebug) "This one has no prefix."

    "foo" `prefixLogs` do
        $(logDebug) "This one has a [foo] prefix."

        "bar" `prefixLogs` do
            $(logDebug) "This one has both [foo] and [bar] prefixes."