Skip to content

Instantly share code, notes, and snippets.

View pivotal-chorus's full-sized avatar

pivotal-chorus

View GitHub Profile
@pivotal-chorus
pivotal-chorus / 20130319164401_create_animals.rb
Created March 19, 2013 21:36
`default_scope` breaks chained scopes in Rails 3.2.13
## db/migrate/20130319164401_create_animals.rb
class CreateAnimals < ActiveRecord::Migration
def change
create_table :animals do |t|
t.boolean :alive
t.timestamps
end
end
end
@pivotal-chorus
pivotal-chorus / gist:5437004
Created April 22, 2013 17:39
Run Jasmine specs from RubyMine. Create the shell script below as an external tool in RubyMine then bind it to a key.
#!/bin/sh
JASMINE_URL="http://localhost:8888/?spec="
if [ -z "$1" ]; then
echo "Opening $JASMINE_URL to run all the tests"
open "$JASMINE_URL"
exit 0
fi