This file contains 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
ei! | |
tsathoggua | |
r'lyeh | |
in his house at r'lyeh dead cthulhu waits dreaming. | |
ph'nglui mglw'nafh cthulhu r'lyeh wgah'nagl fhtagn. | |
yuggoth | |
yoyodyne | |
cthulhu fhtagn! | |
ia! ia! | |
yogsothoth |
This file contains 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
# Requires the redmine_client gem | |
#!/usr/bin/env ruby | |
require 'rubygems' | |
require 'redmine_client' | |
NORMAL = "\e[00;00m" | |
NORMAL_BOLD = "\e[00;01m" | |
YELLOW = "\e[00;33m" | |
BORING_CYAN = "\e[00;36m" |
This file contains 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 MyClass | |
def my_instance_method | |
:some_value | |
end | |
end | |
instance = MyClass.new | |
singleton_class = class << instance; self; end |
This file contains 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 | |
args = ENV["COMP_LINE"].split /\s+/ | |
# "brew" | |
args.shift | |
subcommand = args.shift || '' | |
arg = args.last || '' |
This file contains 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 Proc | |
def *(g) | |
raise ArgumentError, "arity count mismatch" unless arity == g.arity | |
proc { |*a| self[*g[*a] ] } | |
end | |
end | |
class Array | |
def to_proc | |
map(&:to_proc).reverse.inject(&:*) |
This file contains 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
{ | |
"report": | |
[ "object", | |
{ "members": | |
{ | |
"host": "string", | |
"time": "string", | |
"logs": ["array", {"contents": "log_entry"}], | |
"metrics": ["dictionary", {"contents": "metric"}], | |
"resource_statuses": ["dictionary", {"keys": "^[A-Z]\\w*\\[.+\\]$", "contents": "resource_status"}], |
This file contains 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
((file /etc/apache2/apache2.conf | |
(ensure file) | |
(source puppet:///modules/apache/apache2.conf) | |
(notify | |
(service apache | |
(ensure running) | |
(enable true) | |
(require | |
(package apache | |
(ensure latest))))))) |
This file contains 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 | |
if size_opt = ARGV.index('-s') | |
seed = ARGV[size_opt+1] | |
end | |
seed ||= Time.now.to_i | |
if clip_opt = ARGV.index('-c') | |
begin |
This file contains 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 | |
specs_in_order = File.read('spec_order').split | |
failing_spec = ARGV.first | |
specs = specs_in_order[0...specs_in_order.index(failing_spec)] | |
suspects = specs |
This file contains 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
RubyFileStat.java:365:in `cmp': java.lang.ClassCastException: org.jruby.RubySymbol cannot be cast to org.jruby.RubyFileStat | |
from RubyFileStat$i$1$0$cmp.gen:65535:in `call' | |
from RuntimeHelpers.java:2513:in `invokedynamic' | |
from RubyComparable.java:117:in `callCmpMethod' | |
from RubyComparable.java:103:in `op_equal' | |
from RubyComparable$s$1$0$op_equal.gen:65535:in `call' | |
from CachingCallSite.java:312:in `cacheAndCall' | |
from CachingCallSite.java:169:in `call' | |
from EqCallSite.java:37:in `call' | |
from CallOneArgNode.java:57:in `interpret' |
OlderNewer