Open
Description
The R 4.0.0 NEWS file says:
New function R_user_dir() in package tools suggests paths appropriate for storing R-related user-specific data, configuration and cache files.
For example, I currently see:
`tools::R_user_dir("osmextract", "data")`
#> [1] "C:\\Users\\user\\AppData\\Roaming/R/data/R/osmextract"
I think that the ideas behind this function are somewhat related to the approach we currently use to detect where osmextract
functions will save .osm
and .gpkg
files, i.e.
Lines 72 to 78 in 0eeacf8
Currently, we set the download directory as tempdir()
whenever the OSMEXT_DOWNLOAD_DIRECTORY
envvar is not set.
Does it make sense switching to tools::R_user_dir("osmextract", "data")
?