Learn R Programming

renv (version 0.8.2)

status: Status

Description

Report differences between the project's lockfile and the current state of the private library (if any).

Usage

status(project = NULL, ..., library = NULL, lockfile = NULL)

Arguments

project

The project directory. If NULL, then the active project will be used. If no project is currently active, then the current working directory is used instead.

...

Optional arguments; reserved for future expansion.

library

The path to a library. By default, the project library associated with the requested project project is used.

lockfile

The path to a lockfile. By default, the project lockfile (called renv.lock) is used.

Value

This function is normally called for its side effects.

Examples

Run this code
# NOT RUN {
# disable automatic snapshots
auto.snapshot <- getOption("renv.config.auto.snapshot")
options(renv.config.auto.snapshot = FALSE)

# initialize a new project (with an empty R library)
renv::init(bare = TRUE)

# install digest 0.6.19
renv::install("digest@0.6.19")

# save library state to lockfile
renv::snapshot()

# remove digest from library
renv::remove("digest")

# check library status
renv::status()

# restore lockfile, thereby reinstalling digest 0.6.19
renv::restore()

# restore automatic snapshots
options(renv.config.auto.snapshot = auto.snapshot)

# }

Run the code above in your browser using DataLab