Permalink
Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
28 lines (23 sloc) 1.13 KB

Youtube Playlist Widget Thingy

Requirements

  • Ruby (to poll the Youtube API)
  • couchrest rubygem (to store the data in...)
  • CouchDB
  • nodejs (because we need...)
  • npm (node package manager, so we can install...)
  • couchapp (npm install -g couchapp. for uploading design doc to the couchdb)

Install

Once you get all that shit installed, and CouchDB running locally... Pull in the Youtube playlist data:

ruby attachments/couchify_sxsw_youtube_playlists.rb

Then upload the app to couchdb:

couchapp push app.js http://localhost:5984/youtube-sxsw

Make sure your CouchDB is configured to allow JSONP (cross-origin) requests:

allow_jsonp: true

Then visit

http://localhost:5984/youtube-sxsw/_design/by/_rewrite/

Or, you should be able to just open attachments/index.html and things should work.

When loaded in the latter manner, you should be able to edit the html, css and js files and see the results by simply reloading. In order to push your changes up to the couchdb app, you'll need to re-run the couchapp command.