Sucking tweets into a local database

A friend asked me yesterday if I could snap together a script to build a local database of tweets using the twitter search API.

This is what I came up with.

The script takes one argument – the term to search on – and creates a sqlite3 database in the current directory containing all the tweets that the twitter search API returns for that term.

It requires datamapper and twitter_search gems to be installed.

Have at it, make it better, bend it to your twitter-slurping needs.