Implement fs::get_cache_dir

Win32: equal to config dir for now
Linux: respect XDG_CACHE_HOME if specified
OSX: possibly incomplete
This commit is contained in:
Nekotekina 2018-12-24 18:47:46 +03:00
parent 20efed66e9
commit bd9131ae1c
15 changed files with 69 additions and 28 deletions

View file

@ -484,6 +484,9 @@ namespace fs
// Get configuration directory
const std::string& get_config_dir();
// Get common cache directory
const std::string& get_cache_dir();
// Get data/cache directory for specified prefix and suffix
std::string get_data_dir(const std::string& prefix, const std::string& location, const std::string& suffix);