snap: Write installed package versions to a file

Description Usage Arguments Details Value Examples

Description

Base and recommended packages are omitted. Packages that were installed from non-CRAN sources are also included, but you won't be able to restore them with restore.

Usage

1
snap(to = "packages.csv", lib.loc = NULL, recommended = FALSE)

Arguments

to

File to write the package versions to, defaults to packages.csv. If it is NULL, to output file is created and the result is returned as a data frame.

lib.loc

character vector describing the location of R library trees to search through, or NULL for all known trees (see .libPaths).

recommended

if TRUE then recommended packages will be included in the snapshot.

Details

The output file will have two columns, package name and package version.

Value

A two columns data frame, invisibly if it was written to a file.

Examples

1
2
3
snap(to = tmp <- tempfile())

head(read.csv(tmp))

MangoTheCat/pkgsnap documentation built on May 8, 2019, 3:49 p.m.