aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/cmd/postinstall.rb
diff options
context:
space:
mode:
authorXu Cheng2015-08-07 13:56:12 +0800
committerXu Cheng2015-08-08 17:50:49 +0800
commite60dc64828617a6d358687480ce4181fbb1fc12d (patch)
tree4b0ee7673befeaaff778798789e3661de991f5b8 /Library/Homebrew/cmd/postinstall.rb
parent8fecd4c198948dc1d86240b1a3ee4648da49ffe0 (diff)
downloadbrew-e60dc64828617a6d358687480ce4181fbb1fc12d.tar.bz2
only run post_install if it's defined
Closes Homebrew/homebrew#42593. Signed-off-by: Xu Cheng <xucheng@me.com>
Diffstat (limited to 'Library/Homebrew/cmd/postinstall.rb')
-rw-r--r--Library/Homebrew/cmd/postinstall.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/Library/Homebrew/cmd/postinstall.rb b/Library/Homebrew/cmd/postinstall.rb
index 6630afba1..f20b7ad54 100644
--- a/Library/Homebrew/cmd/postinstall.rb
+++ b/Library/Homebrew/cmd/postinstall.rb
@@ -2,7 +2,7 @@ require "sandbox"
module Homebrew
def postinstall
- ARGV.resolved_formulae.each { |f| run_post_install(f) }
+ ARGV.resolved_formulae.select(&:post_install_defined?).each { |f| run_post_install(f) }
end
def run_post_install(formula)