ocamlog

Simple Logger for OCaml
README

Logger pour Ocaml.

Usage

Simple

Fichier exemple bin/main.ml:

open Lib

let () = Ocamlog.print Trace "Message 1"

let () = Ocamlog.print Info "Message 2"

let () = Ocamlog.print Warning "Message 3"

let () = Ocamlog.print Error "Message 4"

Décorations

Fichier exemple bin/main.ml:

open Lib
let () = Ocamlog.enableDecorations ()

let () = Ocamlog.print Trace "Message 1"
let () = Ocamlog.print Info "Message 2"
let () = Ocamlog.print Warning "Message 3"
let () = Ocamlog.print Error "Message 4"

let () = Ocamlog.disableDecorations ()

Inspiration

Merci grand maître Émilien pour cette super idée :
CppLogger2

Install
Sources
v0.2.tar.gz
md5=093992b1204fb4759541a2331808351c
sha512=e55521d9eec0204f88f6c811f57d112f67f5d001efbb3e7880baaf81a724b8cdf82887465de6b84a91b84e5664c5d47835a4bc889de137e8d692aab0957ad18d
Dependencies
dune
>= "2.8"
ocaml
>= "4.04"
Reverse Dependencies