Skip to content

Instantly share code, notes, and snippets.

require "bundler"
Bundler.setup
require "dm-core"
require "dm-types"
require "dm-migrations"
DataMapper.setup(:default, "mysql://localhost/test")
class User
#!/usr/bin/env ruby -Ku
# encoding: utf-8
require 'fileutils'
require 'pathname'
require 'addressable/uri'
require 'ruby-github' # TODO: replace ruby-github with something better maintained

"I am looking forward to accelerating Ruby's progress" - Q&A with Matz regarding joining Heroku as a chief architect.

Date: 13th July 2011

Introduction

As mentioned in my previous article, It has been announced that Yukihiro Matsumoto (Matz) is joining Heroku as Chief Architect of Ruby. I asked Matz about the story behind his future role via email.

My mission is to make Ruby core more functional and higher quality.

@knowtheory
knowtheory / gist:2709760
Created May 16, 2012 11:45
Backbone confusion
var test = Backbone.Model.extend({
var1 : [],
initialize : function(obj) {
this.var1.push("1")
console.log(this.var1.length, this.cid)
}
});
var x = (new test);
# Usage:
# The following will create 5 randomized cards from the lines of gawkerbingo.txt:
# ruby bingorunner.rb 5
require './gawkerbingo.rb'
number_of_cards = ARGV.first.to_i
CreateCards.new(number_of_cards)
# -*- coding: utf-8 -*-
"""
Created on Thu Apr 18 13:10:10 2013
@author: Owner
"""
import sys
import csv
import time