Class: Tane::Commands::Event
Class Method Summary collapse
Methods inherited from Base
Methods included from Helpers
Class Method Details
.help_text ⇒ Object
10 11 12 13 14 15 16 17 18 |
# File 'lib/tane/commands/event.rb', line 10 def help_text <<-EOL Usage: tane event event_category event_name data_hash Notifies the local app of an event. The event category, event name are to be passed along with the data. The data is in the form of a ruby hash with the keys as strings (not symbols!). The following is an example. EOL end |
.process(args) ⇒ Object
4 5 6 7 8 |
# File 'lib/tane/commands/event.rb', line 4 def process(args) event = {'category' => args.first, 'event' => args[1], 'data' => eval(args[2])} puts event post(data_url, event) end |