manifest_from_installed: Generate a TOML manifest from installed packages
Description
Captures all packages installed on .libPaths() and generates
a manifesto-style TOML manifest. Package versions can either reflect
their installed versions, or use a wildcard (*) to accept any.
Usage
manifest_from_installed(
path,
include_base = FALSE,
min_version = c("installed", "*"),
r_version = current_r_version()
)Value
Path to the generated TOML file (invisibly).
Arguments
- path
Optional path to write the manifest. If missing, a temporary .toml file is created.
- include_base
Logical. Whether to include base packages. Defaults to FALSE.
- min_version
Whether to require exact installed versions ('installed', default)
or allow any version via a wildcard ('*').
- r_version
Optional R version settings. Defaults to current_r_version().
Details
Base packages are excluded by default to minimize boilerplate.
Examples
Run this codepath <- manifest_from_installed()
Run the code above in your browser using DataLab