msgInfo: Pre-formatted message functions

View source: R/msgInfo.R

msgInfoR Documentation

Pre-formatted message functions

Description

Convenient wrappers around message() to sent styled notices to the user while a function/script is being executed.

Usage

msgInfo(..., appendLF = TRUE)

msgError(..., appendLF = TRUE)

msgSuccess(..., appendLF = TRUE)

msgWarning(..., appendLF = TRUE)

Arguments

...

text to be passed to paste().

appendLF

a logical. Should messages given as a character string have a new line appended ?

Value

Reports an info.

Functions

  • msgError(): Reports an Error.

  • msgSuccess(): Reports a success.

  • msgWarning(): Reports a warning.

Note

All of these functions call message(), so for any function FUN() using #' them, suppressMessages(FUN()) is sufficient to mute all messages.

See Also

cli::symbol() message()

Examples

msgInfo("computing")
msgSuccess("done")
msgError("you got it wrong")
msgWarning("be careful")

letiR/letiRmisc documentation built on Sept. 11, 2022, 12:43 a.m.