I hereby claim:
- I am danivovich on github.
- I am danivovich (https://keybase.io/danivovich) on keybase.
- I have a public key ASCxJr_4CBEf8zxo6eyWMYfW24NpG3zQlwRI6-0Jkj6Vowo
To claim this, I am signing this object:
%w(autoconf bison build-essential libssl-dev libyaml-dev libreadline6-dev zlib1g-dev libncurses5-dev libffi-dev libgdbm3 libgdbm-dev).each do |pkg| | |
package pkg | |
end |
require 'pivotal-tracker' | |
TOKEN = 'API_TOKEN' | |
PROJECT_NUM = -1 | |
def estimate_to_hours(estimate) | |
2 ** estimate | |
end | |
PivotalTracker::Client.token = TOKEN |
ls -lh `mdfind -onlyin $HOME -name test.log` |
describe 'outer', :one => { :two => 2 } do | |
context 'inner1' do | |
before do | |
example.metadata[:one][:three] = 3 | |
end | |
it 'should have 3' do | |
example.metadata[:one][:three].should == 3 | |
end | |
end |
require 'nokogiri' | |
require 'open-uri' | |
auth_token = 'AUTH_TOKEN' | |
site = 'https://ACCOUNT_NAME.airbrake.io/projects/PROJECT_NUMBER' | |
counts = { | |
:staging => 0, | |
:production => 0 | |
} |
module FactoryGirlStepHelpers | |
def convert_human_hash_to_attribute_hash(human_hash, associations = []) | |
HumanHashToAttributeHash.new(human_hash, associations).attributes | |
end | |
class HumanHashToAttributeHash | |
attr_reader :associations | |
def initialize(human_hash, associations) | |
@human_hash = human_hash |
Then /^render the page$/ do | |
if Capybara.current_driver == Capybara.javascript_driver | |
file_name = "capybara-webkit-#{Time.new.strftime("%Y%m%d%H%M%S")}#{rand(10**10)}.png" | |
name = File.join(*[Capybara.save_and_open_page_path, file_name].compact) | |
page.driver.render name | |
begin | |
require "launchy" # could raise LoadError | |
raise LoadError unless Launchy::Version::MAJOR >= 2 | |
Launchy.open(name) | |
rescue LoadError |
namespace :assets do | |
desc 'Update the URIs for assets used in the static pages (e.g. 500.html)' | |
task :update_static_pages => :environment do | |
manifest_path = Rails.root.join('public', 'assets', 'manifest.yml') | |
unless File.exists?(manifest_path.to_s) | |
raise "Must run assets:precompile first" | |
end | |
manifest = YAML.load(manifest_path.read) | |
%w[404 422 500 504 browser].each do |static_page| | |
path = Rails.root.join('public', "#{static_page}.html") |
I hereby claim:
To claim this, I am signing this object:
import os | |
import signal | |
bind = "127.0.0.1:8888" | |
errorlog = "%s/log/gunicorn.log" % (os.getcwd()) | |
workers = 4 | |
keepalive = 5 | |
preload_app = True | |
def on_starting(server): |