if left unset, will return the user data dir as returned by `tools::R_user_dir` for this package.

hydrogeofetch_data_dir(dir = NULL)

Arguments

dir

path of desired data directory

Value

character path of data directory (silent when setting)

Examples

hydrogeofetch_data_dir()
#> [1] "C:\\Users\\dblodgett\\AppData\\Roaming/R/data/R/hydrogeofetch"

# set it somewhere else, then put it back
old_dir <- hydrogeofetch_data_dir()

hydrogeofetch_data_dir(file.path(tempdir(check = TRUE), "demo"))

hydrogeofetch_data_dir()
#> [1] "C:\\Users\\DBLODG~1\\AppData\\Local\\Temp\\1\\RtmpyYtb0S/demo"

hydrogeofetch_data_dir(old_dir)