aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew
diff options
context:
space:
mode:
authorXu Cheng2015-03-23 01:14:21 +0800
committerXu Cheng2015-03-23 18:35:58 +0800
commit3d255eceb62bca8691fe9baebfde04b6471c4be3 (patch)
tree15523dd7bd7d68e776425098b3d17c2e04e7a407 /Library/Homebrew
parent71bebd28c10a0184aa2bc280f296ca56c618a5a8 (diff)
downloadhomebrew-3d255eceb62bca8691fe9baebfde04b6471c4be3.tar.bz2
install_plist: create var/log path
Let homebrew create var/log path to avoid permission problem. Closes #37966 Closes #37967. Signed-off-by: Xu Cheng <xucheng@me.com>
Diffstat (limited to 'Library/Homebrew')
-rw-r--r--Library/Homebrew/formula_installer.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/Library/Homebrew/formula_installer.rb b/Library/Homebrew/formula_installer.rb
index 5ef6660fd..1e6903be6 100644
--- a/Library/Homebrew/formula_installer.rb
+++ b/Library/Homebrew/formula_installer.rb
@@ -560,6 +560,8 @@ class FormulaInstaller
return unless formula.plist
formula.plist_path.atomic_write(formula.plist)
formula.plist_path.chmod 0644
+ log = formula.var/"log"
+ log.mkpath if formula.plist.include? log.to_s
rescue Exception => e
onoe "Failed to install plist file"
ohai e, e.backtrace if debug?