Idris2Doc : Pack.Core.Logging

Pack.Core.Logging

(source)

Definitions

dataConfirmResult : Type
Totality: total
Visibility: public export
Constructors:
Yes : ConfirmResult
No : ConfirmResult
Unknown : ConfirmResult
log : HasIOio=>LogRef->LogLevel-> Lazy String->io ()
  Logs a message to stdout if the log level is greater than or equal
than the reference level `ref`.
If the given string contains newlines, all lines are printed indented
to the beginning of the first one.

Totality: total
Visibility: export
prompt : HasIOio=>LogLevel->String->ioString
  Logs a message to stdout and reads an reply from stdin.
This uses the given log level but makes sure the message is always
printed no matter the current log level preferences.

Totality: total
Visibility: export
confirm : HasIOio=>LogLevel->String->ioConfirmResult
  Requests confirmation from the user with the specified message and
parses a reply from stdin as `Yes` or `No`.

This uses the given log level but makes sure the message is always
printed no matter the current log level preferences.

Totality: total
Visibility: export
confirmOrAbort : HasIOio=>LogLevel->String->EitherTPackErrio ()
  Requests confirmation from the user with the specified message and
If the reply is not `Yes`, aborts with `SafetyAbort`.

This uses the given log level but makes sure the message is always
printed no matter the current log level preferences.

Totality: total
Visibility: export
logMany : HasIOio=>LogRef=> {defaultFalse_ : Bool} ->LogLevel-> Lazy String-> Lazy (ListString) ->io ()
  Logs an idented list of values to stdout if the given log level
is greater than or equal than the (auto-implicit) reference level `ref`.
If messages list is empty, no log message is printed.

`inlineSingle` parameter being set to `True` makes a single element of
the given list to be printed at the same line as the main message.

Note: Most of the time `ref` is automatically being extracted from
a value of type `Pack.Config.Types.Config` in scope.

Totality: total
Visibility: export
promptMany : HasIOio=>LogLevel->String->ListString->ioString
  Logs an indented list of values to stdout and reads a reply from stdin.

This uses the given log level but makes sure the message is always
printed no matter the current log level preferences.

Totality: total
Visibility: export
confirmMany : HasIOio=>LogLevel->String->ListString->ioConfirmResult
  Logs an indented list of values to stdout and requests confirmation
from the user and parses a reply from stdin as `Yes` or `No`.

This uses the given log level but makes sure the message is always
printed no matter the current log level preferences.

Totality: total
Visibility: export
confirmManyOrAbort : HasIOio=>LogLevel->String->ListString->EitherTPackErrio ()
  Logs an indented list of values to stdout and requests confirmation
from the user. If the reply is not `Yes`, aborts with `SafetyAbort`.

This uses the given log level but makes sure the message is always
printed no matter the current log level preferences.

Totality: total
Visibility: export
debug : HasIOio=>LogRef=> Lazy String->io ()
  Alias for `log ref Debug`.

Note: Most of the time `ref` is automatically being extracted from
a value of type `Pack.Config.Types.Config` in scope.

Totality: total
Visibility: export
info : HasIOio=>LogRef=> Lazy String->io ()
  Alias for `log ref Info`.

Note: Most of the time `ref` is automatically being extracted from
a value of type `Pack.Config.Types.Config` in scope.

Totality: total
Visibility: export
cache : HasIOio=>LogRef=> Lazy String->io ()
  Alias for `log ref Cache`.

Note: Most of the time `ref` is automatically being extracted from
a value of type `Pack.Config.Types.Config` in scope.

Totality: total
Visibility: export
warn : HasIOio=>LogRef=> Lazy String->io ()
  Alias for `log ref Warning`.

Note: Most of the time `ref` is automatically being extracted from
a value of type `Pack.Config.Types.Config` in scope.

Totality: total
Visibility: export
fatal : HasIOio=>PackErr->ioa
  Fail fatally with error message logged.
This is like `System.die` but with error printer like a log message.

Totality: total
Visibility: export