Skip to content

Replace base R message/warning/stop with {cli} #762

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 16 commits into from
Sep 1, 2024
Merged
Prev Previous commit
Next Next commit
Fix interpolation
  • Loading branch information
jamesmbaazam committed Aug 30, 2024
commit f97dc2807ff7baad8d1b5a2e4b3f61032cbc2d39
6 changes: 3 additions & 3 deletions R/setup.R
Original file line number Diff line number Diff line change
Expand Up @@ -41,22 +41,22 @@ setup_logging <- function(threshold = "INFO", file = NULL,
if (!is.null(file)) {
if (mirror_to_console) {
cli_inform(
"Writing {col_blue(\"name\")} logs to the console and: {.file file}."
"Writing {col_blue(name)} logs to the console and: {.file {file}}."
)
futile.logger::flog.appender(
futile.logger::appender.tee(file), name = name
)
} else {
cli_inform(
"Writing {col_blue(\"name\"} logs to: {.file file}."
"Writing {col_blue(name)} logs to: {.file {file}}."
)
futile.logger::flog.appender(
futile.logger::appender.file(file), name = name
)
}
} else {
cli_inform(
"Writing {col_blue(\"name\"} logs to the console."
"Writing {col_blue(name)} logs to the console."
)
futile.logger::flog.appender(futile.logger::appender.console(), name = name)
}
Expand Down