Skip to content

Instantly share code, notes, and snippets.

View nateberkopec's full-sized avatar

Nate Berkopec nateberkopec

View GitHub Profile
fatal: protocol error: expected old/new/ref, got 'shallow 0334aa796da397827fd2e43eb4af3c4b9ac0dff0'
! Heroku Git error, please try again shortly.
! See http://status.heroku.com for current Heroku platform status.
! If the problem persists, please contact http://help.heroku.com and provide Request ID e1d65557-16d7-4608-9a02-f5eccb9911b9.
fatal: The remote end hung up unexpectedly
  • Whip of Erebos
  • Spear of Heliod
  • Agent of the Fates
  • Ashen Rider
  • Boon Satyr
  • Champion of Stray Souls
  • Chromanticore
  • Eidolon of Countless Battles
  • Ephara, God of the Polis
  • Erebos, God of the Dead
RUBY_GC_HEAP_FREE_SLOTS: 600000
RUBY_GC_HEAP_GROWTH_FACTOR: 1.25
RUBY_GC_HEAP_GROWTH_MAX_SLOTS: 200000
RUBY_GC_HEAP_INIT_SLOTS: 600000
RUBY_GC_HEAP_OLDOBJECT_LIMIT_FACTOR: 1.3
RUBY_GC_MALLOC_LIMIT: 16000000
RUBY_GC_MALLOC_LIMIT_MAX: 32000000
RUBY_GC_OLDMALLOC_LIMIT: 16000000
RUBY_GC_OLDMALLOC_LIMIT_MAX: 32000000
$ bundle exec rake guides:generate
.../.rbenv/versions/2.1.0/bin/ruby rails_guides.rb
Generating 2_2_release_notes.md as 2_2_release_notes.html
Generating 2_3_release_notes.md as 2_3_release_notes.html
Generating 3_0_release_notes.md as 3_0_release_notes.html
Generating 3_1_release_notes.md as 3_1_release_notes.html
Generating 3_2_release_notes.md as 3_2_release_notes.html
Generating 4_0_release_notes.md as 4_0_release_notes.html
Generating 4_1_release_notes.md as 4_1_release_notes.html
Generating _license.html.erb as _license.html
$ bundle exec rake guides:generate WARNINGS=1; bundle exec rake guides:validate
.../.rbenv/versions/2.1.0/bin/ruby rails_guides.rb
Generating 2_2_release_notes.md as 2_2_release_notes.html
Generating 2_3_release_notes.md as 2_3_release_notes.html
Generating 3_0_release_notes.md as 3_0_release_notes.html
Generating 3_1_release_notes.md as 3_1_release_notes.html
Generating 3_2_release_notes.md as 3_2_release_notes.html
Generating 4_0_release_notes.md as 4_0_release_notes.html
Generating 4_1_release_notes.md as 4_1_release_notes.html
Generating _license.html.erb as _license.html
class Admin::BaseController < ApplicationController
end
food idea list
tortillas
peanut butter
instant coffee
instant oatmeal
foil packet: potatoes, chicken, fish
ramen
canned chicken, turkey
mac and cheese
Add Sentry to your Gemfile:
gem "sentry-raven", :require => 'raven', :git => "https://github.com/getsentry/raven-ruby.git"
Add a config/initializers/raven.rb containing:
Raven.configure do |config|
config.dsn = 'https://ee561c4bd99f45c6bb2a442b1af04677:34f0a36cb8f54ca7beb35aaed895725f@app.getsentry.com/31964'
end
def prepare_bodies(message)
messages = message.scan(/.{1,130}\b/)
return messages if messages.length == 1
messages.each_with_index.map do |s, i|
"(#{i + 1}/#{messages.length}) #{s}"
end
end
class Order < ActiveRecord::Base
has_one :payment
def complete
payment.complete
end
end
class Payment < ActiveRecord::Base
belongs_to :gateway_transaction
def complete