Class: RssNotifier::Cli
- Inherits:
-
Thor
- Object
- Thor
- RssNotifier::Cli
- Defined in:
- lib/rss_notifier/cli.rb
Instance Method Summary collapse
Instance Method Details
#init ⇒ Object
11 12 13 |
# File 'lib/rss_notifier/cli.rb', line 11 def init RssNotifier::App.init(force: .force?) end |
#start ⇒ Object
22 23 24 25 26 27 28 29 |
# File 'lib/rss_notifier/cli.rb', line 22 def start unless .notify? RssNotifier.logger.warn "Notifcation is disabled. To enable, run $ rss_notifier start --notify".red end app = RssNotifier::App.new(notify: .notify?) app.run end |
#version ⇒ Object
16 17 18 |
# File 'lib/rss_notifier/cli.rb', line 16 def version puts RssNotifier::VERSION end |