aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorL. E. Segovia2017-11-29 01:02:50 +0000
committerL. E. Segovia2017-11-29 01:02:50 +0000
commitab62be5345ddd30813aef1d1772a131bd0c32fa5 (patch)
treea7bd991933c4c25d85b07149e22c8cd70bf3389f
parent657d4eaee9eccecea6052c5759ea68e31e28693e (diff)
downloadbrew-ab62be5345ddd30813aef1d1772a131bd0c32fa5.tar.bz2
Implement @reitermarkus's comments
Leftover && and remove xattr "copy"
-rw-r--r--Library/Homebrew/cask/lib/hbc/artifact/moved.rb2
-rw-r--r--Library/Homebrew/cask/lib/hbc/installer.rb12
2 files changed, 6 insertions, 8 deletions
diff --git a/Library/Homebrew/cask/lib/hbc/artifact/moved.rb b/Library/Homebrew/cask/lib/hbc/artifact/moved.rb
index dfd6008cf..f5ef790eb 100644
--- a/Library/Homebrew/cask/lib/hbc/artifact/moved.rb
+++ b/Library/Homebrew/cask/lib/hbc/artifact/moved.rb
@@ -70,8 +70,6 @@ module Hbc
else
command.run("/bin/mv", args: [target, source], sudo: true)
end
-
- add_altname_metadata(source, target.basename, command: command)
end
def delete(target, force: false, command: nil, **_)
diff --git a/Library/Homebrew/cask/lib/hbc/installer.rb b/Library/Homebrew/cask/lib/hbc/installer.rb
index 5879cd3e1..f7b837959 100644
--- a/Library/Homebrew/cask/lib/hbc/installer.rb
+++ b/Library/Homebrew/cask/lib/hbc/installer.rb
@@ -459,12 +459,12 @@ module Hbc
# Homebrew-Cask metadata
if backup_metadata_path.respond_to?(:children) &&
- backup_metadata_path.exist? &&
- backup_metadata_path.children.each do |subdir|
- unless PERSISTENT_METADATA_SUBDIRS.include?(subdir.basename)
- gain_permissions_remove(subdir)
- end
- end
+ backup_metadata_path.exist?
+ backup_metadata_path.children.each do |subdir|
+ unless PERSISTENT_METADATA_SUBDIRS.include?(subdir.basename)
+ gain_permissions_remove(subdir)
+ end
+ end
end
backup_metadata_path.rmdir_if_possible
end