#' @title Move the documents files
#' @description Copy the files of a packaged \code{drake} workflow into a supplied directory.
#' @param to Character scalar, file path, where to write the folders containing the workflow's files.
#' @return `NULL`
#' @importFrom purrr map
#' @importFrom purrr walk2
#' @examples
#'
#' @export
move_ospsreports_files <- function(to = getwd()){
# Check that the directories match the names of the overwrite_dirs
directories<-list.files("documents", recursive = TRUE)
purrr::walk(paste0("documents/", unique(gsub("/.*","\\1",directories))), ~file.copy(.x,
to = to, recursive = TRUE))
unlink("documents", recursive = TRUE)
invisible()
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.