# Inspect the cache directory (no side effects)
wa_cache_dir()
# \dontshow{
# Safe demo: redirect cache to a temp folder, create a file, then clear it
old <- getOption("writeAlizer.cache_dir"); on.exit(options(writeAlizer.cache_dir = old), add = TRUE)
tmp <- file.path(tempdir(), "wa_cache_demo"); dir.create(tmp, recursive = TRUE, showWarnings = FALSE)
options(writeAlizer.cache_dir = tmp)
writeLines("demo", file.path(wa_cache_dir(), "demo.txt"))
wa_cache_clear(ask = FALSE)
# }
Run the code above in your browser using DataLab