R/zzz_onAttach.R

.onAttach <- function (lib, pkg) {
    pkg.info <- drop(read.dcf(
        file = system.file("DESCRIPTION", package = "labestData"),
        fields = c("Package", "Title", "Version", "Date", "URL")
    ))
    dashes <- paste0(rep("----------", times = 7), collapse = "")
    packageStartupMessage(
        paste0(dashes, "\n  ",
               pkg.info["Package"], ": ", pkg.info["Title"], "\n\n  ",
               "Para colabora\u00e7\u00e3o, suporte ou ",
               "relato de bugs, visite:\n    ",
               sub(x = pkg.info["URL"],
                   pattern = "\n",
                   replacement = "\n    "), "\n\n  ",
               pkg.info["Package"], " version ", pkg.info["Version"],
               " (feito em ", pkg.info["Date"], ") foi carregado.\n",
               dashes)
    )
}
pet-estatistica/labestData documentation built on May 25, 2019, 12:47 a.m.