Skip to content

Commit

Permalink
Merge pull request #179563 from Homebrew/more-getting-rid-of-rmtree
Browse files Browse the repository at this point in the history
*casks: Replace `rmtree` with `rm_r`
  • Loading branch information
issyl0 committed Jul 15, 2024
2 parents b99499b + 6248751 commit 908c7b2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Casks/g/google-cloud-sdk.rb
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@

preflight do
FileUtils.cp_r staged_path/"google-cloud-sdk/.", google_cloud_sdk_root, remove_destination: true
(staged_path/"google-cloud-sdk").rmtree
FileUtils.rm_r(staged_path/"google-cloud-sdk")
FileUtils.ln_s google_cloud_sdk_root, (staged_path/"google-cloud-sdk")
end

Expand Down
3 changes: 2 additions & 1 deletion developer/bin/casks-without-zap
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@

# rubocop:disable Style/TopLevelMethodDefinition

require "fileutils"
require "find"
require "json"
require "open-uri"
Expand All @@ -13,7 +14,7 @@ require "tmpdir"

# Exit cleanup
TMP_DIR = Pathname.new(Dir.mktmpdir).freeze
at_exit { TMP_DIR.rmtree }
at_exit { FileUtils.rm_r(TMP_DIR) }

# Constants
ONLINE_ISSUE = "https://github.com/Homebrew/homebrew-cask/issues/88469"
Expand Down

0 comments on commit 908c7b2

Please sign in to comment.