powered by
This gives you a minimal logger with no appenders that you can use inside your package under the name lg (e.g. lg$fatal("test")). use_logger() does not modify any files but only prints code for you to copy and paste.
lg
use_logger()
use_logger(pkg = desc::desc_get("Package", rprojroot::find_package_root_file("DESCRIPTION"))[[1]])
character scalar. Name of the package. The default is to try to get the Package name automatically using the packages rprojroot and desc
character
a character scalar containing R code.
# NOT RUN { use_logger("testpkg") # }
Run the code above in your browser using DataLab