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
# This is just a portion of the (November 17th, 2007) file ... | |
def filtered_body(comment) | |
body = comment.body | |
if comment.posted_by =~ /href="mailto:jerseymcjones@gmail.com"/ | |
parser = HTMLTree::XMLParser.new(false,false) | |
parser.feed("<html>#{body}</html>") | |
xml = parser.document | |
encheferize(xml.root) | |
body = '' |
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
begin | |
require 'bundler/inline' | |
rescue LoadError => e | |
$stderr.puts 'Bundler version 1.10 or later is required. Please update your Bundler' | |
raise e | |
end | |
gemfile(true) do | |
source 'https://rubygems.org' | |
gem 'rails', github: 'rails/rails' |
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 'rspec' | |
require 'forwardable' | |
# This is a cleaner implementation of Forwardable. It does not use string evaluation, | |
# nor does it have any rescues in it. This code grew out of a discussion at RubiABQ | |
# http://www.meetup.com/Rubyists-in-Albuquerque/events/225108828/ | |
module MyForwardable |
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 'set' | |
COUNTS = [ 1490, 482, 207, 122].freeze # 1490 have 1 ticket, 482 have 2, etc. | |
N_DRAWS = 275 | |
USER_MAP = {} |
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 | |
# $VERBOSE = true | |
require 'rubygems' | |
require 'ri_cal' | |
require 'tzinfo' | |
# We're in Albuquerque, so we make Mountain time our time zone |