delete_if_cache_directory {styler}R 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.


[Package styler version 1.10.3 Index]