aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/cmd
diff options
context:
space:
mode:
authorXu Cheng2015-07-31 17:53:42 +0800
committerXu Cheng2015-07-31 19:52:36 +0800
commit2ebd1c974beb072d11defa368a85bbe0746c1135 (patch)
treedc71abd2771721498acf3e9ddf826cbbca5a1512 /Library/Homebrew/cmd
parent8054161153b598d392b0be25a882ae87a5455726 (diff)
downloadbrew-2ebd1c974beb072d11defa368a85bbe0746c1135.tar.bz2
print sandbox message
Closes Homebrew/homebrew#42293. Signed-off-by: Xu Cheng <xucheng@me.com>
Diffstat (limited to 'Library/Homebrew/cmd')
-rw-r--r--Library/Homebrew/cmd/postinstall.rb8
-rw-r--r--Library/Homebrew/cmd/test.rb8
2 files changed, 12 insertions, 4 deletions
diff --git a/Library/Homebrew/cmd/postinstall.rb b/Library/Homebrew/cmd/postinstall.rb
index 337fc62be..6630afba1 100644
--- a/Library/Homebrew/cmd/postinstall.rb
+++ b/Library/Homebrew/cmd/postinstall.rb
@@ -15,8 +15,12 @@ module Homebrew
#{formula.path}
].concat(ARGV.options_only)
- if Sandbox.available? && ARGV.sandbox? && Sandbox.auto_disable?
- Sandbox.print_autodisable_warning
+ if Sandbox.available? && ARGV.sandbox?
+ if Sandbox.auto_disable?
+ Sandbox.print_autodisable_warning
+ else
+ Sandbox.print_sandbox_message
+ end
end
Utils.safe_fork do
diff --git a/Library/Homebrew/cmd/test.rb b/Library/Homebrew/cmd/test.rb
index d298452ff..7c3641426 100644
--- a/Library/Homebrew/cmd/test.rb
+++ b/Library/Homebrew/cmd/test.rb
@@ -35,8 +35,12 @@ module Homebrew
#{f.path}
].concat(ARGV.options_only)
- if Sandbox.available? && ARGV.sandbox? && Sandbox.auto_disable?
- Sandbox.print_autodisable_warning
+ if Sandbox.available? && ARGV.sandbox?
+ if Sandbox.auto_disable?
+ Sandbox.print_autodisable_warning
+ else
+ Sandbox.print_sandbox_message
+ end
end
Utils.safe_fork do