return package dependencies from NAMESPACE file

att_from_namespace(path = "NAMESPACE", document = TRUE, clean = TRUE)

Arguments

path

path to NAMESPACE file

document

Run function roxygenise of roxygen2 package

clean

Logical. Whether to remove the original NAMESPACE before updating

Value

a vector

Examples

tmpdir <- tempdir() file.copy(system.file("dummypackage",package = "attachment"), tmpdir, recursive = TRUE)
#> [1] TRUE
dummypackage <- file.path(tmpdir, "dummypackage") # browseURL(dummypackage) att_from_namespace(path = file.path(dummypackage, "NAMESPACE"))
#> Updating dummypackage documentation
#> Updating roxygen version in /private/var/folders/24/8k48jl6d249_n_qfxwsl6xvm0000gn/T/RtmpWgA2Y5/dummypackage/DESCRIPTION
#> Loading dummypackage
#> Writing NAMESPACE #> Writing NAMESPACE
#> [1] "magrittr"