devtools (version 1.9.1)

revdep_check_save_logs: Run R CMD check on all downstream dependencies.

Description

Use revdep_check() to run check_cran() on all downstream dependencies. Summarises the results with revdep_check_summary and save logs with revdep_check_save_logs.

Usage

revdep_check_save_logs(res, log_dir = "revdep")

revdep_check_save_summary(res, log_dir = "revdep")

revdep_check_summary(res)

revdep_check(pkg = ".", recursive = FALSE, ignore = NULL, dependencies = c("Depends", "Imports", "Suggests", "LinkingTo"), libpath = getOption("devtools.revdep.libpath"), srcpath = libpath, bioconductor = FALSE, type = getOption("pkgType"), threads = getOption("Ncpus", 1), check_dir = tempfile("check_cran"))

Arguments

res
Result of revdep_check
log_dir
Directory in which to save logs
pkg
Path to package. Defaults to current directory.
recursive
If TRUE look for full set of recursive dependencies.
ignore
A character vector of package names to ignore. These packages will not appear in returned vector. This is used in revdep_check to avoid packages with installation problems or extremely long check times
dependencies
A character vector listing the types of dependencies to follow.
libpath
Path to library to store dependencies packages - if you you're doing this a lot it's a good idea to pick a directory and stick with it so you don't have to download all the packages every time.
srcpath
Path to directory to store source versions of dependent packages - again, this saves a lot of time because you don't need to redownload the packages every time you run the package.
bioconductor
If TRUE also look for dependencies amongst bioconductor packages.
type
binary Package type to test (source, mac.binary etc). Defaults to the same type as install.packages().
threads
Number of concurrent threads to use for checking. It defaults to the option "Ncpus" or 1 if unset.
check_dir
Directory to store results.

Value

  • An invisible list of results. But you'll probably want to look at the check results on disk, which are saved in check_dir. Summaries of all ERRORs and WARNINGs will be stored in check_dir/00check-summary.txt.

Check process

  1. Installpkg(in special library, see below).
  2. Find all CRAN packages that depend onpkg.
  3. Install those packages, along with their dependencies.
  4. RunR CMD checkon each package.
  5. Uninstallpkg(so other reverse dependency checks don't use the development version instead of the CRAN version)

Package library

By default revdep_check uses a temporary library to store any packages that are required by the packages being tested. This ensures that they don't interfere with your default library, but means that if you restart R between checks, you'll need to reinstall all the packages. If you're doing reverse dependency checks frequently, I recommend that you create a directory for these packages and set options(devtools.revdep.libpath).

See Also

revdep_maintainers() to run R CMD check on all reverse dependencies.

Examples

Run this code
# Run R CMD check on all downstream dependencies of ggplot2
res <- revdep_check("ggplot2")
revdep_check_summary(res)
revdep_check_save_logs(res)

Run the code above in your browser using DataCamp Workspace