Skip to content

Instantly share code, notes, and snippets.

@hoelzro
Created May 24, 2011 21:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save hoelzro/989678 to your computer and use it in GitHub Desktop.
Save hoelzro/989678 to your computer and use it in GitHub Desktop.
module('mybot.wikipedia')
command = 'wiki'
local function get_mw_results(url, query)
-- do something
end
function handlemessage(msg)
local body = msg.body
local results = get_mw_results('http://en.wikipedia.org', body)
return table.concat(results, '\n')
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment