log_enable {ptspotter} | R Documentation |
log_enable
Description
Assigns the necessary global scope objects for logging with "log4r".
Usage
log_enable(
logfile_loc = NULL,
pos = 1,
logger_nm = my_logger,
appender_nm = file_app
)
Arguments
logfile_loc |
The path to the logfile. Suggested use "logs/logfile.txt". |
pos |
The environment which to assign pipeline_message. Defaults to 1, equivalent to the .GlobalEnv. |
logger_nm |
What to call the logger. Provide unquoted strings with no spaces. Defaults to my_logger. |
appender_nm |
What to call the appender function. Provide unquoted strings with no spaces. Defaults to file_app. |
Value
Creates logger and file appender.
Examples
# create logging infrastructure
log_file_ops(dir_path = "logs/logfile.txt")
# enable logging
log_enable(logfile_loc = "logs/logfile.txt")
# tidy up environment
unlink("logs", recursive = TRUE)
[Package ptspotter version 1.0.2 Index]