pac_deps {pacs} | R Documentation |
Package dependencies
Description
Package dependencies from DESCRIPTION files with installed or expected versions or newest released.
Usage
pac_deps(
pac,
fields = c("Depends", "Imports", "LinkingTo"),
lib.loc = .libPaths(),
base = FALSE,
local = TRUE,
description_v = FALSE,
attr = TRUE,
recursive = TRUE,
repos = biocran_repos()
)
Arguments
pac |
|
fields |
|
lib.loc |
|
base |
|
local |
logical if to use local repository (or newest remote packages). Default: TRUE |
description_v |
|
attr |
|
recursive |
|
repos |
|
Value
data.frame
with packages and their versions. Versions are taken from installed.packages
or newest released.
Note
When function is invoked in the loop afterwards results could be aggregated like,
stats::aggregate(results[, c("Version"), drop = FALSE], list(Package = results$Package), pacs::compareVersionsMax)
.
Examples
## Not run:
pacs::pac_deps("stats", base = TRUE)$Package
pacs::pac_deps("memoise")$Package
pacs::pac_deps("memoise", description_v = FALSE)
# raw dependencies from DESCRIPTION file
pacs::pac_deps("memoise", description_v = TRUE, recursive = FALSE)
# raw dependencies from DESCRIPTION file - last release
pacs::pac_deps("memoise", description_v = TRUE, local = FALSE, recursive = FALSE)
## End(Not run)