put caveats in finish after post_install Homebrew/homebrew#42565
When running brew -v install, long post_install output from the formula, presumably from upstream, may hide the important instructions in the caveats and confuse the user. For example, postgresql runs initdb which prints its own instructions for running the database, making the caveats scroll off screen. Per xu-cheng's instructions in Homebrew/homebrew#42565 : Remove the explicit call to caveats from the install, reinstall, and upgrade commands, as well as the dependency installer code in FormulaInstaller#install_dependency , and call caveats right before the summary code in FormulaInstaller#finish . Closes Homebrew/homebrew#42565. Signed-off-by: Xu Cheng <xucheng@me.com>
This commit is contained in:
parent
3518cda792
commit
74b18bfe12
@ -176,7 +176,6 @@ module Homebrew
|
||||
fi.debug = ARGV.debug?
|
||||
fi.prelude
|
||||
fi.install
|
||||
fi.caveats
|
||||
fi.finish
|
||||
rescue FormulaInstallationAlreadyAttemptedError
|
||||
# We already attempted to install f as part of the dependency tree of
|
||||
|
@ -27,7 +27,6 @@ module Homebrew
|
||||
fi.debug = ARGV.debug?
|
||||
fi.prelude
|
||||
fi.install
|
||||
fi.caveats
|
||||
fi.finish
|
||||
rescue FormulaInstallationAlreadyAttemptedError
|
||||
# next
|
||||
|
@ -67,7 +67,6 @@ module Homebrew
|
||||
outdated_keg.unlink if outdated_keg
|
||||
|
||||
fi.install
|
||||
fi.caveats
|
||||
fi.finish
|
||||
|
||||
# If the formula was pinned, and we were force-upgrading it, unpin and
|
||||
|
@ -364,7 +364,6 @@ class FormulaInstaller
|
||||
fi.prelude
|
||||
oh1 "Installing #{formula.full_name} dependency: #{Tty.green}#{dep.name}#{Tty.reset}"
|
||||
fi.install
|
||||
fi.caveats
|
||||
fi.finish
|
||||
rescue Exception
|
||||
ignore_interrupts do
|
||||
@ -409,6 +408,8 @@ class FormulaInstaller
|
||||
end
|
||||
end
|
||||
|
||||
caveats
|
||||
|
||||
ohai "Summary" if verbose? || show_summary_heading?
|
||||
puts summary
|
||||
ensure
|
||||
|
Loading…
x
Reference in New Issue
Block a user