Skip to content

Instantly share code, notes, and snippets.

-- % spec -fs matcher_spec.rb
a string
- should should be pretty lengthy
- can be short
- can be long
- can be too short (FAILED - 1)
- can be too long (FAILED - 2)
1)
[Wed Apr 08 16:09:15 2009] [error] [client 98.212.135.224] Premature end of script headers: profile, referer: http://my-web-site-not.example.com/profile/pictures
[ pid=17938 file=Hooks.cpp:502 time=2009-04-08 16:09:15.667 ]:
Backend process 17974 did not return a valid HTTP response. It returned no data.
# Run this from oly-dev
rm -rf */vendor/libs/{aasm,haml,rspec_hpricot_matchers}
rm -rf */vendor/plugins/{better_partials,cucumber,rspec,webrat,will_paginate}
rm -rf */vendor/rails
describe 'an ApplicationController spec', :shared => true do
before(:all) do
ActionController::Routing::Routes.draw do |map|
map.resources :foo
map.connect '/access', :controller => 'foo', :action => 'access', :conditions => { :method => :put }
map.login '/login', :controller => 'foo', :action => 'index'
end
end
after(:all) do
xmonad.hs:155:7:
Ambiguous occurrence `font'
It could refer to either `XMonad.Prompt.font',
imported from XMonad.Prompt at xmonad.hs:26:1-20
or `Dzen.font',
imported from Dzen at xmonad.hs:35:1-11
(defined at lib/Dzen.hs:89:7)
@pd
pd / clone.sh
Last active December 10, 2015 21:29 — forked from anonymous/window_layout_spec.rb
mkdir -p read_window_layout/features/support
curl https://gist.github.com/raw/4495802/9d28d175fc1808e86e29248df793c01460cf7119/read-layout.feature > read_window_layout/features/read-layout.feature
curl https://gist.github.com/raw/4495802/ba67bac9506bda4522883f19c118fef23604db9e/features-support-env.rb > read_window_layout/features/support/env.rb
bindings combos.mash,
'R': -> App.reloadConfig
'F': (win) -> win.maximize
'U': relocate (loc) -> loc.fillColumn()
'H': relocate (loc) -> loc.move('column', -1)
'J': relocate (loc) -> loc.move('row', 1)
'K': relocate (loc) -> loc.move('row', -1)
'L': relocate (loc) -> loc.move('column', 1)
@pd
pd / 00_before.txt
Last active December 20, 2015 16:19
puzzle 0 solved in 111ms
puzzle 1 solved in 387ms
puzzle 2 solved in 403ms
puzzle 3 solved in 18174ms
puzzle 4 solved in 5284ms
puzzle 5 solved in 59081ms
puzzle 6 solved in 17535ms
puzzle 7 solved in 240ms
puzzle 8 solved in 13946ms
puzzle 9 solved in 19302ms
@pd
pd / example.txt
Created August 8, 2013 18:12
let's call it an mvp
$ npm i esprima falafel
$ node sib.js | node
{ '4': [ [ 2, 'big' ], [ 2, 'big' ] ],
'8': [ [ 6, 'little' ] ],
'11': [ [ 11, 'big' ], [ 11, 'little' ] ] }
@pd
pd / fail.rb
Created October 25, 2014 18:25
Reproducing hoxworth/json-schema issue #96
# https://github.com/hoxworth/json-schema/issues/96
require 'json-schema'
schema = {
:type => :object,
:required => [
:id,
:name,
:real_name,