No commit activity in last 3 years
No release in over 3 years
XKCD searchable archive for comics by keyword, id and date*. * date coming soon to a minor update near you
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

~> 1.3
~> 0.8
~> 0.6
~> 10.4
~> 3.3
~> 0.10

Runtime

~> 4
~> 2.0
~> 0.18
~> 4.27
~> 1.6
 Project Readme

lita-onewheel-xkcd

image

image

A Lita handler to display XKCD comics in your chat handler of choice.

Installation

Get a postgres instance running, give this guy access to write to the two tables in scripts/schema.rb. Add lita-onewheel-xkcd to your Lita instance's Gemfile: :: gem "lita-onewheel-xkcd"

Configuration

Unless you're running the defaults, you'll want to specify your database connection values like so: :: Lita.configure do config.handlers.onewheel_xkcd.db_host = 'localhost' config.handlers.onewheel_xkcd.db_name = 'lita_xkcd' config.handlers.onewheel_xkcd.db_user = 'root' config.handlers.onewheel_xkcd.db_pass = '' config.handlers.onewheel_xkcd.db_port = 5432 config.handlers.onewheel-xkcd.alt_delay = 15 # Optional; 9 is the default. end

Usage

All commands return the comic, and then display the alt text alt_delay seconds later.

xkcd

Returns a random XKCD comic.

xkcd 411

Returns xkcd.com/411's comic.

xkcd ballmer

returns my favorite Steve Ballmer comic.

xkcd next

returns the next comic by index.

xkcd prev

returns the previous comic by index.

xkcdupdate

Updates the database with the latest comics. Manually, for now.

Engineering Notes

Current comic(including top number): http://xkcd.com/info.0.json

Comic by number: http://xkcd.com/1/info.0.json

How to map # to date? - it's in the meta

Keyword tokenizer, it's substring searching at the moment.

Add postgres setup and details on how to update the database with new comics.