trevorturk/eldorado

unable to launch app without hoptoad

Closed this issue · 5 comments

there are some things missing if you don't want to use hoptoad.

  1. environment.rb is trying to require the gem regardless of config key missing (no if there)
  2. lib/tasks/hoptoad_notifier_tasks.rake is require'ing the file as above.

apart from those, heroku is only for pgsql and not mysql :(

Thanks for reporting -- any chance of a pull request?

Too little for doing a fork imho ;)
Here's a diff:

iff --git a/config/environment.rb b/config/environment.rb
index 3d13198..b398814 100644
--- a/config/environment.rb
+++ b/config/environment.rb
@@ -15,5 +15,5 @@ Rails::Initializer.run do |config|
config.gem "right_http_connection", :version => "1.2.4"
config.gem "searchlogic", :version => "2.3.9"
config.gem "will_paginate", :version => "2.3.15"

  • config.gem "hoptoad_notifier", :version => "2.2.2"
    -end
    \ No newline at end of file
  • config.gem "hoptoad_notifier", :version => "2.2.2" if CONFIG['hoptoad_key']
    +end
    diff --git a/lib/tasks/hoptoad_notifier_tasks.rake b/lib/tasks/hoptoad_notifier_tasks.rake
    index da2f45f..3f8ba85 100644
    --- a/lib/tasks/hoptoad_notifier_tasks.rake
    +++ b/lib/tasks/hoptoad_notifier_tasks.rake
    @@ -2,4 +2,5 @@ Dir[File.join(RAILS_ROOT, 'vendor', 'gems', 'hoptoad_notifier-*')].each do |vend
    $: << File.join(vendored_notifier, 'lib')
    end

-require 'hoptoad_notifier/tasks'
+CONFIG = YAML.load_file('config/config.yml')[RAILS_ENV] rescue {}
+require 'hoptoad_notifier/tasks' if CONFIG['hoptoad_key']

It'd be much easier for me to merge a pull request -- I'm traveling and don't have access to my normal work environment.

did that. sorry if I did something wrong, this is my first experience with doing pull/push things with git :)

Merged - thanks!