eraseDirectory: Erase all files in a directory

View source: R/MGDrivE-Auxiliary.R

eraseDirectoryR Documentation

Erase all files in a directory

Description

Given a directory path, check that it exists, and if so, delete all its contents.

Usage

eraseDirectory(directory, verbose = TRUE)

Arguments

directory

Directory whose contents will be deleted

verbose

Chatty? Default is TRUE

Examples

## Not run: 
# Path to directory, can tilde expand
myPath <- "~/path/to/write/output"

# Erase directory
#  No return value
eraseDirectory(directory = myPath)

## End(Not run)


MGDrivE documentation built on Sept. 9, 2025, 5:42 p.m.