delete_if_cache_directory: Delete a cache or temp directory

View source: R/zzz.R

delete_if_cache_directoryR Documentation

Delete a cache or temp directory

Description

For safety, path is only deleted if it is a sub-directory of a temporary directory or user cache. Since this function relies on tools::R_user_dir(), it early returns FALSE on ⁠R < 4.0.0⁠.

Usage

delete_if_cache_directory(path)

Arguments

path

Absolute path to a directory to delete.

Value

TRUE if anything was deleted, FALSE otherwise.


styler documentation built on Aug. 29, 2023, 5:10 p.m.