mirror of
https://github.com/Homebrew/brew.git
synced 2025-07-14 16:09:03 +08:00
onoe and opoo print to stderr
This may result in some undesired output for things that suppress stdout, but we'll fix those as we go. Fixes Homebrew/homebrew#18650.
This commit is contained in:
parent
7af5a74c4e
commit
ba202df70b
@ -50,13 +50,13 @@ def oh1 title
|
|||||||
end
|
end
|
||||||
|
|
||||||
def opoo warning
|
def opoo warning
|
||||||
puts "#{Tty.red}Warning#{Tty.reset}: #{warning}"
|
STDERR.puts "#{Tty.red}Warning#{Tty.reset}: #{warning}"
|
||||||
end
|
end
|
||||||
|
|
||||||
def onoe error
|
def onoe error
|
||||||
lines = error.to_s.split'\n'
|
lines = error.to_s.split("\n")
|
||||||
puts "#{Tty.red}Error#{Tty.reset}: #{lines.shift}"
|
STDERR.puts "#{Tty.red}Error#{Tty.reset}: #{lines.shift}"
|
||||||
puts lines unless lines.empty?
|
STDERR.puts lines unless lines.empty?
|
||||||
end
|
end
|
||||||
|
|
||||||
def ofail error
|
def ofail error
|
||||||
|
Loading…
x
Reference in New Issue
Block a user