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
|
yield self
|
||||||
rescue Interrupt, RuntimeError, SystemCallError => e
|
rescue Interrupt, RuntimeError, SystemCallError => e
|
||||||
unless ARGV.debug?
|
unless ARGV.debug?
|
||||||
logs = File.expand_path '~/Library/Logs/Homebrew/'
|
%w(config.log CMakeCache.txt).select{|f| File.exist? f}.each do |f|
|
||||||
if File.exist? 'config.log'
|
HOMEBREW_LOGS.install f
|
||||||
mkdir_p logs
|
ohai "#{f} was copied to #{HOMEBREW_LOGS}"
|
||||||
mv 'config.log', logs
|
|
||||||
end
|
|
||||||
if File.exist? 'CMakeCache.txt'
|
|
||||||
mkdir_p logs
|
|
||||||
mv 'CMakeCache.txt', logs
|
|
||||||
end
|
end
|
||||||
raise
|
raise
|
||||||
end
|
end
|
||||||
|
|||||||
@ -51,6 +51,9 @@ else
|
|||||||
HOMEBREW_REPOSITORY+"Cellar"
|
HOMEBREW_REPOSITORY+"Cellar"
|
||||||
end
|
end
|
||||||
|
|
||||||
|
HOMEBREW_LOGS = Pathname.new('~/Library/Logs/Homebrew/').expand_path
|
||||||
|
|
||||||
|
|
||||||
MACOS_FULL_VERSION = `/usr/bin/sw_vers -productVersion`.chomp
|
MACOS_FULL_VERSION = `/usr/bin/sw_vers -productVersion`.chomp
|
||||||
MACOS_VERSION = /(10\.\d+)(\.\d+)?/.match(MACOS_FULL_VERSION).captures.first.to_f
|
MACOS_VERSION = /(10\.\d+)(\.\d+)?/.match(MACOS_FULL_VERSION).captures.first.to_f
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user