Skip to content

Commit

Permalink
Merge pull request #18328 from notfirefox/fix-rubocop-cache
Browse files Browse the repository at this point in the history
style: resolve symblic links in `HOMEBREW_CACHE`
  • Loading branch information
MikeMcQuaid authored Sep 16, 2024
2 parents 8fd78bf + bb4208e commit 8f5c745
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Library/Homebrew/style.rb
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,9 @@ def self.run_rubocop(files, output_type,

args += files

cache_env = { "XDG_CACHE_HOME" => "#{HOMEBREW_CACHE}/style" }
HOMEBREW_CACHE.mkpath
cache_dir = HOMEBREW_CACHE.realpath
cache_env = { "XDG_CACHE_HOME" => "#{cache_dir}/style" }

FileUtils.rm_rf cache_env["XDG_CACHE_HOME"] if reset_cache

Expand Down

0 comments on commit 8f5c745

Please sign in to comment.