A few Ruby scripts to backup Delicious bookmarks to CouchDB and provide some simple queries
-
a pre-Yahoo Delicious account as they use HTTP Basic Auth for authentication
-
CouchDB running on port 5984 on your local machine, I recommend the binary distributions from CouchOne
-
nokogiri and couchrest gems must be installed
sudo gem install nokogiri couchrest
git clone https://github.com/stevenwilkin/delicious-couch
cd delicious-couch
Substitute your username and password on the command line
USER=username PASS=password ./import.rb
./views.rb
Now that the database had been populated and the views created, the contents can be queried
./list_urls.rb
./count_tags.rb
./urls_by_tag.rb git
Views all bookmarks tagged with "git"
This set of scripts is only scraping the surface of what is possible with CouchDB but it demonstrates the immense power of MapReduce along with the basics interacting with CouchDB using Ruby. Enjoy!
2010 Steven Wilkin