Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

fixing heroku rails generator #169

Closed
wants to merge 1 commit into
from

Conversation

Projects
None yet
2 participants
Owner

mmcdaris commented Jan 12, 2013

Please review my fix for the heroku rails generator fix
:)

@mmcdaris mmcdaris commented on the diff Jan 12, 2013

lib/rails/generators/airbrake/airbrake_generator.rb
@@ -91,7 +89,7 @@ def api_key_configured?
end
def test_airbrake
- puts run("rake airbrake:test")
+ puts run("airbrake raise")
@mmcdaris

mmcdaris Jan 12, 2013

Owner

This provides cleaner output, ty @shime for making airbrake raise

@mmcdaris mmcdaris commented on the diff Jan 12, 2013

lib/rails/generators/airbrake/airbrake_generator.rb
@@ -77,13 +77,11 @@ def heroku_var(var,app_name = nil)
end
def heroku_api_key
- heroku_var("AIRBRAKE_API_KEY",options[:app]).split.find {|x| x unless x.blank?}
+ "'#{`heroku config:get AIRBRAKE_API_KEY`.gsub("\n","")}'"
@mmcdaris

mmcdaris Jan 12, 2013

Owner

ask heroku what the api key is
parse the newline out of the result

Contributor

shime commented Jan 12, 2013

Looks great! 👍

Can you please just double check the removed generator? I think we're using that for Rails 2 so we should leave that intact.

@shime shime closed this May 20, 2013

@kyrylo kyrylo deleted the heroku_fix branch Oct 23, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment