find_srcpkgs: finds all available source packages starting from the project root
Description
N.B: the hidden files and directories are ignored.
In general, this function is not used directly, instead you should use get_srcpkgs()
Usage
find_srcpkgs(
root = get_project_root(),
srcpkgs_paths = find_srcpkgs_paths(root, prune = prune),
prune = TRUE
)
Value
a "srcpkgs" object (or NULL if none found), a named list of "srcpkg" objects, that essentially are
devtools "package" objects. The list is named after the package names.
Arguments
- root
directory from where to search for source packages
- srcpkgs_paths
paths to the source packages folders
- prune
whether to report packages contained inside another package (e.g. in tests/)
Examples
Run this codepkg <- setup_and_get_dummy_srcpkg()
pkgs <- find_srcpkgs(dirname(pkg$path))
print(pkgs)
Run the code above in your browser using DataLab