Skip to contents

Writes a message to the console depending on whether cli is installed or not.

Usage

FM_message(line, escape_braces = TRUE, entry_type = "alert")

Arguments

line

Text to display

escape_braces

Set to TRUE (default) to escape curly braces in the entry, set to FALSE to have the values interpreted.

entry_type

Set to either "alert"(default), "danger", "info", "success", "warning", "h1", "h2", or "h3"

Value

Returns NULL

Examples

mr = FM_message("This is a normal  message")
#> → This is a normal  message
mr = FM_message("This is a danger  message", entry_type="danger")
#>  This is a danger  message
mr = FM_message("This is a info    message", entry_type="info")
#>  This is a info    message
mr = FM_message("This is a success message", entry_type="success")
#>  This is a success message
mr = FM_message("This is a warning message", entry_type="warning")
#> ! This is a warning message
mr = FM_message("This is an H1 header",      entry_type="h1")
#> 
#> ── This is an H1 header ────────────────────────────────────────────────────────
mr = FM_message("This is an H2 header",      entry_type="h2")
#> 
#> ── This is an H2 header ──
#> 
mr = FM_message("This is an H3 header",      entry_type="h3")
#> ── This is an H3 header