Permalink
Browse files

Add "retrieve gist" example

  • Loading branch information...
1 parent 2dd9067 commit f4a8288dede79d90e303a22cb6654488c381f198 @meritt committed Aug 16, 2011
Showing with 10 additions and 0 deletions.
  1. +10 −0 example/gist.coffee
View
@@ -0,0 +1,10 @@
+###
+ Retrieve public gist
+###
+
+Gisty = require('./../lib/gisty').Gisty
+
+gist = new Gisty()
+gist.fetch '1111422', (error, gist) ->
+ throw new Error error if error
+ console.log "#{filename}\n--------------\n\n#{file.content}\n\n" for filename, file of gist.files

0 comments on commit f4a8288

Please sign in to comment.