diff options
Diffstat (limited to 'scaffolder/src/Text/Edifact/Scaffolder/Commons/Logging.hs')
-rw-r--r-- | scaffolder/src/Text/Edifact/Scaffolder/Commons/Logging.hs | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/scaffolder/src/Text/Edifact/Scaffolder/Commons/Logging.hs b/scaffolder/src/Text/Edifact/Scaffolder/Commons/Logging.hs new file mode 100644 index 0000000..1287f7f --- /dev/null +++ b/scaffolder/src/Text/Edifact/Scaffolder/Commons/Logging.hs | |||
@@ -0,0 +1,11 @@ | |||
1 | module Text.Edifact.Scaffolder.Commons.Logging | ||
2 | ( say | ||
3 | ) where | ||
4 | |||
5 | import Control.Monad.IO.Class (MonadIO, liftIO) | ||
6 | import qualified Data.Text.Lazy.Builder as TLB (toLazyText) | ||
7 | import qualified Data.Text.Lazy.IO as TLIO (putStrLn) | ||
8 | import Formatting as F (Format, runFormat) | ||
9 | |||
10 | say :: MonadIO m => Format (m ()) a -> a | ||
11 | say m = runFormat m (liftIO . TLIO.putStrLn . TLB.toLazyText) | ||