Skip to content

Instantly share code, notes, and snippets.

@sarahhodne
Created January 28, 2010 19:54
Show Gist options
  • Save sarahhodne/289076 to your computer and use it in GitHub Desktop.
Save sarahhodne/289076 to your computer and use it in GitHub Desktop.
plugin(:echo) do
name 'Echo Plugin'
author 'Henrik Hodne <[email protected]>'
command(:echo, '*') do |from, params|
from.privmsg(params)
end
end
class EchoPlugin < Lime::Plugin
name 'Echo Plugin'
author 'Henrik Hodne <[email protected]>'
command :echo, '*'
def echo(from, params)
from.privmsg(params)
end
end
class EchoPlugin
def initialize
Lime.register(:command, :echo, '*', method(:echo))
end
def echo(from, params)
from.privmsg(params)
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment