This package provides yet another variant of Bolt OCaml logging tool called VLT derived from Volt logging tool. Unlike Volt, VLT relies on ppx instead of camlp4 to preprocess source code. In addition to the original Bolt (except preprocessor), VLT offers the following features:
Original logging syntax modified for ppx log_expr ::= [%LOG level (string|ident) {arg}* {attr}* ]
level ::= | [%FATAL] | [%ERROR] | [%WARN] | [%INFO] | [%DEBUG] | [%TRACE]
attr ::= | [%NAME string ] | [%(PROPERTIES | WITH) expr ] | [%(EXCEPTION | EXN) expr ]
Extended logging syntax log_expr ::= ... | [%fatal_log (string|ident) {arg}* {attr}* ] | [%error_log (string|ident) {arg}* {attr}* ] | [%warn_log (string|ident) {arg}* {attr}* ] | [%info_log (string|ident) {arg}* {attr}* ] | [%debug_log (string|ident) {arg}* {attr}* ] | [%trace_log (string|ident) {arg}* {attr}* ]
block_expr ::= | begin%fatal_block expr_seq end | begin%error_block expr_seq end | begin%warn_block expr_seq end | begin%info_block expr_seq end | begin%debug_block expr_seq end | begin%trace_block expr_seq end
[%NAME ... ] attribute is provided. Note that, unlike Volt, you have to enclose each toplevel structure_item in [%%capture_path ... ].[%LOG ... ] and *_log expressions are not evaluated when the defined logger does not record events.The development sources are available from GitHub.
As in the original version, this tool is free software released under the LGPLv3.
$ dune build
$ dune installThe original Bolt is Copyright (C) 2009-2012 Xavier Clerc and released under the LGPLv3. The official website of Bolt is here.
Copyright © 2023 Codinuum Software Lab