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 ActiveRecord::Reflection::AssociationReflection | |
class AmbiguousAssociationClassError < Exception | |
def initialize results | |
super "Could not guess association, please specify using class_name. Likely options: #{results.join(', ')}" | |
end | |
end | |
def klass | |
super | |
rescue NameError |
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
bundler: bundle exec guard --plugin bundler --no-interactions | |
db: postgres -D /opt/boxen/homebrew/var/postgres | |
integration: bundle exec guard --plugin cucumber --no-interactions | |
mailcatcher: mailcatcher --foreground --verbose | |
redis: redis-server /opt/boxen/homebrew/etc/redis.conf | |
test: bundle exec guard --plugin rspec --no-interactions | |
web: bundle exec guard --plugin unicorn --no-interactions | |
worker: bundle exec sidekiq |
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
@mixin blur($much: 10px) { | |
-webkit-filter: blur($much); | |
// Force hardware acceleration for vastly improved performance | |
-webkit-transform: translate3d(0, 0, 0); | |
} |
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
# Quiz Exercise, Part One | |
# | |
# Quiz for a list of names & birthdays, | |
# then list out their ages | |
# | |
# For example: | |
# | |
# Hey there! Please enter a list of names: | |
# > John, Sam, Bob, Alisha, Henry | |
# |
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 VeryVeryBadException < RuntimeError | |
end | |
begin | |
raise VeryVeryBadException, "winter is coming" |
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
def bouncer(name, age = 18) | |
if age < 21 | |
puts "Go away, #{name}" | |
else | |
puts "OK" | |
end | |
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
# Quiz Exercise, Part One | |
# | |
# Quiz for a list of names & birthdays, | |
# then list out their ages | |
# | |
# For example: | |
# | |
# Hey there! Please enter a list of names: | |
# > John, Sam, Bob, Alisha, Henry | |
# |
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
# Quiz Exercise, Part One | |
# | |
# Quiz for a name and birthday, | |
# then display the age | |
# | |
# For example: | |
# | |
# Hey there! Please enter your name: | |
# > John | |
# |
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
# Quiz Exercise, Part One | |
# | |
# Quiz for a list of names & birthdays, | |
# then list out their ages | |
# | |
# For example: | |
# | |
# Hey there! Please enter a list of names: | |
# > John, Sam, Bob, Alisha, Henry | |
# |
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
# Quiz Exercise, Part One | |
# | |
# Quiz for a name and birthday, | |
# then display the age | |
# | |
# For example: | |
# | |
# Hey there! Please enter your name: | |
# > John | |
# |