Module: Herald::Watcher::Notifier::Stdout
- Defined in:
- lib/herald/notifiers/stdout.rb
Instance Method Summary collapse
-
#notify(item) ⇒ Object
print to $stdout.
- #parse_options(options) ⇒ Object
-
#test ⇒ Object
is always working, so true.
Instance Method Details
#notify(item) ⇒ Object
print to $stdout
18 19 20 21 |
# File 'lib/herald/notifiers/stdout.rb', line 18 def notify(item) $stdout.puts item.data.inspect $stdout.flush end |
#parse_options(options) ⇒ Object
7 8 9 10 11 12 |
# File 'lib/herald/notifiers/stdout.rb', line 7 def () # option to send stdout to file if file = .delete(:file) $stdout = File.new(file, 'w') end end |
#test ⇒ Object
is always working, so true
15 |
# File 'lib/herald/notifiers/stdout.rb', line 15 def test; true; end |