View source: R/spot_unused_files.R
spot_unused_files | R Documentation |
spot_unused_files
spot_unused_files(
path = ".",
file.extensions = c("png", "jpg", "jpeg", "gif", "bmp", "tiff", "tif", "csv", "xls",
"xlsx", "txt"),
script.extensions = c("R", "Rmd", "qmd"),
archive = FALSE,
ignore.folder = "./docs"
)
path |
A character string with the path to the directory to be analyzed. Default is current directory. |
file.extensions |
A character vector with the file extensions to be considered. Default is c("png", "jpg", "jpeg", "gif", "bmp", "tiff", "tif", "csv", "xls", "xlsx", "txt"). |
script.extensions |
A character vector with the script extensions to be considered. Default is c("R", "Rmd", "qmd"). |
archive |
A logical value indicating whether to archive the unused files. If |
ignore.folder |
A character string with the path or paths to the directory(ies) to be ignored. Default is "./docs". |
This function is used to spot/remove unused files in a project directory. It is useful to keep the project directory clean and organized. It is recommended to first run the function with a the argument archive = FALSE
to spot which files are being spotted and then run archive = TRUE
if they need to be removed.
Returns a data frame with 2 columns: file.name (self explanatory) and folder (where the file is found).
Marcelo Araya-Salas (marcelo.araya@ucr.ac.cr)
Araya-Salas, M., Arriaga, A. (2023), sketchy: research compendiums for data analysis in R. R package version 1.0.3.
add_to_gitignore
, make_compendium
{
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.