R/rusage.r

Defines functions rusage

Documented in rusage

#' Check variable usage
#'
#' @description
#' Checks the package using \code{\link[codetools:checkUsage]{checkUsagePackage}}
#'
#' @template path
#' @template return-itrue
#' @export
rusage = function(path = getwd()) {
  pkgload::load_all(path = path)
  requireNamespace("codetools")

  messagef("Checking usage for package '%s' ...", pkgload::pkg_name(path))
  codetools::checkUsagePackage(pkgload::pkg_name(path))
  invisible(TRUE)
}
rdatsci/rt documentation built on Dec. 6, 2020, 5:31 p.m.