Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

View mcfiredrill's full-sized avatar
💭
working on datafruits

Tony Miller mcfiredrill

💭
working on datafruits
View GitHub Profile
FacebookWrapper = double('facebook')
FacebookWrapper.stub(:new) { double('graph') }
likes = Array({"category"=>"Media/news/publishing",
"name"=>"Zigg(Kawaii Culture Media)",
"created_time"=>"2014-03-17T05:52:31+0000",
"id"=>"486930078012376"})
graph.stub(:likes).with(:id).and_return(likes)
Fortchan12.PostsRoute = Ember.Route.extend model: -> Ember.RSVP.hash posts: @get('store').findAll 'post' newPost: @get('store').createRecord 'post'
<h2>make a new post</h2>
<form {{action 'create' newPost on="submit"}}>
{{#if isSaving}}
<p>saving post...</p>
{{/if}}
<p>{{input type="text" value=name}}</p>
<p>{{textarea value=body}}</p>
<button type="submit">Create</button>
</form>
🍒tony@moguya ~/src/elixir_stuff$ elixir chat.ex
** (CompileError) chat.ex:74: Chat.Room.__struct__/0 is undefined, cannot expand struct Chat.Room
(elixir) src/elixir_map.erl:55: :elixir_map.translate_struct/4
(elixir) src/elixir.erl:195: :elixir.quoted_to_erl/3
(elixir) src/elixir_lexical.erl:17: :elixir_lexical.run/2
🍒tony@moguya ~/src/elixir_stuff$ elixir -v
Elixir 0.14.2
@mcfiredrill
mcfiredrill / gist:472678f7deed7382b7d8
Created August 5, 2014 03:03
platform privacy policies/terms of service
io
unicode/utf8
math
bytes
bufio
syscall
strconv
time
reflect
os
@mcfiredrill
mcfiredrill / PACKAGES
Created August 19, 2014 08:55
liquidsoap PACKAGES
# Edit this file by (un)commenting the libraries that you (don't) want to
# build in order to get the corresponding features in liquidsoap.
# The default file has every dependency enabled.
# It is certain that you don't need everything.
# If you don't know why you should have something, uncomment it,
# especially if it does not build for some reason.
# It is useless to add savonet packages that are not listed below,
# like ocaml-fetch, ocaml-smbclient, etc. These are not dependencies of
class Foo
constructor: () ->
@a = 'hey'
wat: =>
console.log(@a)
w = new Foo
w.wat
#!/usr/bin/env ruby
Bundler.require
require_relative './playlist_download_job'
R = Redis.new
next_song = R.lpop "datafruits.fm:playlist"
if next_song != nil
puts next_song
else
** [out :: 192.168.50.4] / [38/708]
** [out :: 192.168.50.4] -
** [out :: 192.168.50.4] \
** [out :: 192.168.50.4] |
** [out :: 192.168.50.4] /
** [out :: 192.168.50.4] -
** [out :: 192.168.50.4] \
** [out :: 192.168.50.4] |
** [out :: 192.168.50.4] /
** [out :: 192.168.50.4] -