I hereby claim:
- I am trydionel on github.
- I am trydionel (https://keybase.io/trydionel) on keybase.
- I have a public key ASAqp_aOZqcmAe0F12Mvs7kjsW8ly1MaSbxkQY6XnRIFWgo
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
Jeff Tucker | |
9:04 AM (1 hour ago) | |
to support, billing | |
You do realize I'm no longer a customer of yours, right? You've freaked me out with these | |
emails 4-5 times over the last month -- 2 new billing emails (with a zero balance, | |
thankfully) and a few warnings that my non-existant server is being moved. This is | |
terrible -- you're going out of your way to ensure I'll never be a customer again. Please | |
stop contacting me. |
#!/usr/bin/env ruby | |
paths = ARGV | |
paths.each do |path| | |
Dir["#{path}/*"].each do |file| | |
asset = File.basename(file) | |
search = `ack -ai1 --ignore-dir=tmp --ignore-dir=log #{asset}`.strip | |
if search.length.zero? | |
ext = File.extname(asset) |
// Rails-style JSON serialization. e.g., Given a form: | |
// | |
// <input type="text" name="foo[bar][]" value="qux" /> | |
// <input type="text" name="foo[bar][]" value="quux" /> | |
// | |
// $("form").serializeJSON() will serialize to | |
// | |
// { foo: { bar: [ "qux", "quux" ] } } | |
// | |
$.fn.serializeJSON = function() { |
ruby-1.8.7-p302 :001 > require 'builder' | |
=> true | |
ruby-1.8.7-p302 :002 > xm = Builder::XmlMarkup.new; nil | |
=> nil | |
ruby-1.8.7-p302 :003 > xm.title('foo'); nil | |
=> nil | |
ruby-1.8.7-p302 :004 > puts xm.target! | |
<title>foo</title> | |
=> nil |
// | |
// Backbone.Rails.js | |
// | |
// Makes Backbone.js play nicely with the default Rails setup, i.e., | |
// no need to set | |
// ActiveRecord::Base.include_root_in_json = false | |
// and build all of your models directly from `params` rather than | |
// `params[:model]`. | |
// | |
// Load this file after backbone.js and before your application JS. |
class SuperClass | |
def run | |
return "foo" | |
end | |
end | |
class SubClass < SuperClass | |
def run | |
super | |
return "bar" |
require 'rubygems' | |
require 'haml' | |
require 'sinatra' | |
require 'redis' | |
helpers do | |
def redis | |
@redis ||= Redis.new | |
end | |
end |