Skip to contents

Extract the packages dependencies, name of the dependency, operator and version for each type and package of current repositories (getOptions("repos")).

Usage

repos_dependencies(which = "all")

Arguments

which

a character vector listing the types of dependencies, a subset of c("Depends", "Imports", "LinkingTo", "Suggests", "Enhances"). Character string "all" is shorthand for that vector, character string "most" for the same vector without "Enhances", character string "strong" (default) for the first three elements of that vector.

Value

A data.frame with 5 columns: the name of the dependency, the operator (op), the version it depends the type of dependency and the package.

Examples

rd <- repos_dependencies()
#> Retrieving repos_dependencies, this might take a bit.
#> Next call will be faster.
head(rd)
#>           name   op version     type  package
#> 1            R   >=  2.15.0  Depends       A3
#> 2      pbapply <NA>    <NA>  Depends       A3
#> 3       xtable <NA>    <NA>  Depends       A3
#> 4        e1071 <NA>    <NA> Suggests       A3
#> 5 randomForest <NA>    <NA> Suggests       A3
#> 6            R   >=   3.6.0  Depends AATtools