Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Update packages

Source:R/update.R
update.Rd

Update packages which are currently out-of-date. Currently supports CRAN,Bioconductor, other CRAN-like repositories, GitHub, GitLab, Git, andBitBucket.

Updates will only be checked from the same source – for example,if a package was installed from GitHub, but a newer version isavailable on CRAN, that updated version will not be seen.

Usage

update(  packages=NULL,...,  exclude=NULL,  library=NULL,  type=NULL,  rebuild=FALSE,  check=FALSE,  prompt=interactive(),  lock=FALSE,  all=FALSE,  project=NULL)

Arguments

packages

A character vector ofR packages to update. WhenNULL(the default), all packages (apart from any listed in theignored.packagesproject setting) will be updated.

...

Unused arguments, reserved for future expansion. If any argumentsare matched to..., renv will signal an error.

exclude

A set of packages to explicitly exclude from updating.Userenv::update(exclude = <...>) to update all packages except fora specific set of excluded packages.

library

TheR library to be used. WhenNULL, the active projectlibrary will be used instead.

type

The type of package to install ("source" or "binary"). Defaultsto the value ofgetOption("pkgType").

rebuild

Force packages to be rebuilt, thereby bypassing any installedversions of the package available in the cache? This can either be aboolean (indicating that all installed packages should be rebuilt), or avector of package names indicating which packages should be rebuilt.

check

Boolean; check for package updates without actuallyinstalling available updates? This is useful when you'd like to determinewhat updates are available, without actually installing those updates.

prompt

Boolean; prompt the user before taking any action? For backwardscompatibility,confirm is accepted as an alias forprompt.

lock

Boolean; update therenv.lock lockfile after the successfulinstallation of the requested packages?

all

Boolean; shouldrenv check all library paths for out-of-datepackages? WhenFALSE (the default), only the project library will bechecked for out-of-date packages.

project

The project directory. IfNULL, then the active project willbe used. If no project is currently active, then the current workingdirectory is used instead.

Value

A named list of package records which were installed by renv.

Examples

if(FALSE){# \dontrun{# update the 'dplyr' packagerenv::update("dplyr")}# }

[8]ページ先頭

©2009-2025 Movatter.jp