Package 'universe'

Title: Tools for Working with R-universe <https://r-universe.dev>
Description: Utilities to interact with the R-universe platform. Includes functions to manage local package repositories, as well as API wrappers for retrieving data and metadata about packages in r-universe.
Authors: Jeroen Ooms [aut, cre]
Maintainer: Jeroen Ooms <[email protected]>
License: Apache License (>= 2)
Version: 1.0.0
Built: 2024-08-29 22:56:01 UTC
Source: https://github.com/ropensci/universe

Help Index


Enable a package repository from r-universe

Description

Adds r-universe package repositories to your options("repos") such that they are used by default in install.packages(). If the universe was already enabled, it will not be added again, hence it is harmless to call this function multiple times.

Usage

add(universe = "ropensci")

remove(universe)

Arguments

universe

vector with name(s) of the universe(s), i.e. the subdomain part of ⁠https://ropensci.r-universe.dev⁠.

Details

Note that changes to your options are not permanent. To automatically enable a repository for every R session, you can call this function in your ~/.Rprofile script.

Value

the updated list of repositories


Download snapshot

Description

Downloads a full copy (snapshot) of an R package repository.

Usage

repo_snapshot(repo, destdir = "snapshot", bin_versions = r_version())

r_version()

Arguments

repo

url of the cran-like repository to snapshot

bin_versions

vector with versions of R to download the win/mac binary packages. The default is to download binaries only for your local version. Set to NULL to not download any binaries.

Examples

repo_snapshot('https://jeroen.r-universe.dev', bin_versions = c("4.1", "4.2", "4.3"))