aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/cask
diff options
context:
space:
mode:
authorMarkus Reiter2017-03-08 16:35:02 +0100
committerMarkus Reiter2017-03-08 16:49:28 +0100
commit88bc68f3b5fb623e953b1103e211b6f7c77dbe1f (patch)
tree2ab950eecb7e80a69d75170942f35ddd24f87cb4 /Library/Homebrew/cask
parentef02414888ec332aa4220fe05428f24b9a4f035f (diff)
downloadbrew-88bc68f3b5fb623e953b1103e211b6f7c77dbe1f.tar.bz2
Always `chmod +x` `binary` stanzas.
Diffstat (limited to 'Library/Homebrew/cask')
-rw-r--r--Library/Homebrew/cask/lib/hbc/artifact/binary.rb5
-rw-r--r--Library/Homebrew/cask/lib/hbc/artifact/relocated.rb2
2 files changed, 6 insertions, 1 deletions
diff --git a/Library/Homebrew/cask/lib/hbc/artifact/binary.rb b/Library/Homebrew/cask/lib/hbc/artifact/binary.rb
index 9136d6a2a..395ab5c5c 100644
--- a/Library/Homebrew/cask/lib/hbc/artifact/binary.rb
+++ b/Library/Homebrew/cask/lib/hbc/artifact/binary.rb
@@ -6,6 +6,11 @@ module Hbc
def install_phase
super if CLI.binaries?
end
+
+ def link(artifact_spec)
+ super(artifact_spec)
+ FileUtils.chmod "+x", source
+ end
end
end
end
diff --git a/Library/Homebrew/cask/lib/hbc/artifact/relocated.rb b/Library/Homebrew/cask/lib/hbc/artifact/relocated.rb
index aa12dfa4a..bd68ccad0 100644
--- a/Library/Homebrew/cask/lib/hbc/artifact/relocated.rb
+++ b/Library/Homebrew/cask/lib/hbc/artifact/relocated.rb
@@ -35,7 +35,7 @@ module Hbc
altnames = "(#{altnames})"
# Some packges are shipped as u=rx (e.g. Bitcoin Core)
- @command.run!("/bin/chmod", args: ["--", "u=rwx", file.to_s, file.realpath.to_s])
+ @command.run!("/bin/chmod", args: ["--", "u+rw", file.to_s, file.realpath.to_s])
@command.run!("/usr/bin/xattr",
args: ["-w", ALT_NAME_ATTRIBUTE, altnames, file.to_s],