diff --git a/lib/datasets/cache-path.rb b/lib/datasets/cache-path.rb index aa061759..4a418f27 100644 --- a/lib/datasets/cache-path.rb +++ b/lib/datasets/cache-path.rb @@ -15,13 +15,14 @@ def remove private def system_cache_dir + return ENV['XDG_CACHE_HOME'] if ENV['XDG_CACHE_HOME'] case RUBY_PLATFORM when /mswin/, /mingw/ ENV['LOCALAPPDATA'] || '~/AppData/Local' when /darwin/ '~/Library/Caches' else - ENV['XDG_CACHE_HOME'] || '~/.cache' + '~/.cache' end end end