Description Usage Details Value Examples
Create a temporary directory to where output files can be redirected for
examination and later cleanup. Once the output files have been written to the
redirection directory, apply any needed tests to them to examine their
content. Thereafter, cleanup can be performed by deleting the directory and
its content in one go, e.g. by using fs::dir_delete()
.
1 |
You may wish to defer the cleanup to a cleanup handler such as on.exit()
or
withr::defer()
. The local_re_dir()
function does this for you.
re_dir Newly created uniquely named temporary directory.
1 2 3 | re_dir <- create_re_dir()
# Do something with the re_dir directory
fs::dir_delete(re_dir)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.