This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| object :user do | |
| object :profile do | |
| object :nested do | |
| attributes :property | |
| end | |
| end | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| require 'ruby-processing' | |
| # Pird | |
| class Pird < Processing::App | |
| load_library "minim" | |
| import "ddf.minim" | |
| import "ddf.minim.analysis" | |
| load_library "control_panel" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| module CarrierWave | |
| module FFMPEG | |
| extend ActiveSupport::Concern | |
| module ClassMethods | |
| def faststart | |
| process :faststart => true | |
| end | |
| def transcode options |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| require 'formula' | |
| class TmuxForIterm2 < Formula | |
| url 'http://iterm2.googlecode.com/files/tmux-for-iTerm2-20120108.tar.gz' | |
| md5 'f15d9f567b9b029482bb7b3227ee7ac3' | |
| homepage 'http://code.google.com/p/iterm2/downloads/detail?' + | |
| 'name=tmux-for-iTerm2-20120108.tar.gz' | |
| depends_on 'libevent' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class DeferredGarbageCollection | |
| DEFERRED_GC_THRESHOLD = (ENV['DEFER_GC'] || 15.0).to_f | |
| @@last_gc_run = Time.now | |
| def self.start | |
| GC.disable if DEFERRED_GC_THRESHOLD > 0 | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| module CarrierWave | |
| module FFMPEG | |
| extend ActiveSupport::Concern | |
| module ClassMethods | |
| def faststart | |
| process :faststart => true | |
| end | |
| def transcode options |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Precompile all assets | |
| # config.assets.precompile = [ /\.coffee$/, /\.css\.scss\$/ ] | |
| config.assets.precompile += [ | |
| Proc.new{ |path| File.basename(path) =~ /^[^_][\w\.]+?\.(js|css)$/ }, | |
| ] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| require 'sproutcore' | |
| require 'sproutcore-statechart' | |
| require 'sproutcore-routing' | |
| App = SC.Application.create() | |
| App.GlobalNavController = SC.Object.create( | |
| home: -> App.statechart.gotoState 'home' | |
| about: -> App.statechart.gotoState 'about' | |
| ) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var mediator = function (obj) { | |
| var channels = {}; | |
| if (!obj) obj = {}; | |
| obj.subscribe = function (channel, subscription) { | |
| if (!channels[channel]) channels[channel] = []; | |
| channels[channel].push(subscription); | |
| }; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env ruby | |
| require 'rubygems' | |
| require 'koala' | |
| require 'benchmark' | |
| require 'optparse' | |
| require 'yaml' | |
| require 'json' | |
| @session_token = nil |