Tell the user when build logs are copied
This commit is contained in:
parent
04088ba96d
commit
aef580261b
@ -192,14 +192,9 @@ class Formula
|
||||
yield self
|
||||
rescue Interrupt, RuntimeError, SystemCallError => e
|
||||
unless ARGV.debug?
|
||||
logs = File.expand_path '~/Library/Logs/Homebrew/'
|
||||
if File.exist? 'config.log'
|
||||
mkdir_p logs
|
||||
mv 'config.log', logs
|
||||
end
|
||||
if File.exist? 'CMakeCache.txt'
|
||||
mkdir_p logs
|
||||
mv 'CMakeCache.txt', logs
|
||||
%w(config.log CMakeCache.txt).select{|f| File.exist? f}.each do |f|
|
||||
HOMEBREW_LOGS.install f
|
||||
ohai "#{f} was copied to #{HOMEBREW_LOGS}"
|
||||
end
|
||||
raise
|
||||
end
|
||||
|
||||
@ -51,6 +51,9 @@ else
|
||||
HOMEBREW_REPOSITORY+"Cellar"
|
||||
end
|
||||
|
||||
HOMEBREW_LOGS = Pathname.new('~/Library/Logs/Homebrew/').expand_path
|
||||
|
||||
|
||||
MACOS_FULL_VERSION = `/usr/bin/sw_vers -productVersion`.chomp
|
||||
MACOS_VERSION = /(10\.\d+)(\.\d+)?/.match(MACOS_FULL_VERSION).captures.first.to_f
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user