Sha256: 08b5e5f711f0de5215a4a07d089b8ecced4794085d60ca8287ec6412c4fccb35

Contents?: true

Size: 361 Bytes

Versions: 1

Compression:

Stored size: 361 Bytes

Contents

Ego.plugin do |robot|
  robot.can 'output text to the terminal'

  # Provide #say, #emote, #alert, and #debug
  robot.extend(Ego::Printer)

  # A verbose robot doesn't suppress #debug output
  robot.provide :verbose? do
    @options.verbose
  end

  robot.can 'repeat what you say'
  robot.on(/^(?:say|echo)\s+(?<input>.+)/i) do |input|
    say input
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
ego-0.5.0 lib/ego/plugins/robot_io.rb