set_app_cache_dir: Set a Cache Directory for an App

View source: R/path.R

set_app_cache_dirR Documentation

Set a Cache Directory for an App

Description

Override the default paths used by app_cache_dir().

Usage

set_app_cache_dir(appname, cache_dir = NULL)

Arguments

appname

Character; the name of the application that will "own" the cache, such as the name of a package.

cache_dir

Character scalar; a path to a cache directory.

Value

A normalized path to a cache directory. The directory is created if the user has write access and the directory does not exist. An option is also set so future calls to app_cache_dir() will respect the change.

Examples


# Executing this function creates a cache directory.
set_app_cache_dir(appname = "dlr", cache_dir = "/my/cache/path")


macmillancontentscience/dlr documentation built on Sept. 24, 2022, 12:50 p.m.