
Below are the sets presently available, and their corresponding id. if you don't set an ID, one will be randomly chosen every run. Emoji icons may not render in certain terminals.
(pass, fail, pending)
| group :production do | |
| gem 'unicorn' | |
| # Enable gzip compression on heroku, but don't compress images. | |
| gem 'heroku-deflater' | |
| # Heroku injects it if it's not in there already | |
| gem 'rails_12factor' | |
| end |
| #!/bin/bash | |
| while [ 1 ] | |
| do | |
| rsync -avz --partial source dest | |
| if [ "$?" = "0" ] ; then | |
| echo "rsync completed normally" | |
| exit | |
| else | |
| echo "Rsync failure. Backing off and retrying..." |
| require "timeout" | |
| module WaitSteps | |
| extend RSpec::Matchers::DSL | |
| matcher :become_true do | |
| match do |block| | |
| begin | |
| Timeout.timeout(Capybara.default_wait_time) do | |
| sleep(0.1) until value = block.call |
Locate the section for your github remote in the .git/config file. It looks like this:
[remote "origin"]
fetch = +refs/heads/*:refs/remotes/origin/*
url = [email protected]:joyent/node.git
Now add the line fetch = +refs/pull/*/head:refs/remotes/origin/pr/* to this section. Obviously, change the github url to match your project's URL. It ends up looking like this:
| module DelayedJob | |
| module Matchers | |
| def enqueue_delayed_job(handler) | |
| DelayedJobMatcher.new handler | |
| end | |
| class DelayedJobMatcher | |
| def initialize(handler) | |
| @handler = handler | |
| @attributes = {} |
| # The following recipe works with upstream rails proxy for custom 404s and 500s. | |
| # Errors are usually handled via rails except if proxy is really down, in which case | |
| # nginx needs a bit more configration. | |
| server { | |
| # ... | |
| location / { | |
| error_page 404 = @rails; # let rails show a page with suggestions | |
| try_files maintenance.html @rails; |
Get Homebrew installed on your mac if you don't already have it
Install highlight. "brew install highlight". (This brings down Lua and Boost as well)
| require "money" | |
| class Decorator < BasicObject | |
| undef_method :== | |
| def initialize(component) | |
| @component = component | |
| end | |
| def method_missing(name, *args, &block) |