Permalink
Browse files

don't load entire environment for deploy task

closes #110
  • Loading branch information...
1 parent 8fdefb8 commit c92688642063452719b4a52ce45fb669ef0c9f26 @shime shime committed Aug 23, 2012
Showing with 2 additions and 1 deletion.
  1. +2 −1 lib/airbrake/shared_tasks.rb
@@ -1,7 +1,8 @@
namespace :airbrake do
desc "Notify Airbrake of a new deploy."
- task :deploy => :environment do
+ task :deploy do
require 'airbrake_tasks'
+ load File.join(Rails.root, 'config', 'initializers','airbrake.rb') if defined?(Rails.root)
@exviva

exviva Sep 7, 2012

Contributor

This file may not exist in Rails.root - in our case it's located in a Rails engine, which we mount to multiple Rails apps.

AirbrakeTasks.deploy(:rails_env => ENV['TO'],
:scm_revision => ENV['REVISION'],
:scm_repository => ENV['REPO'],

0 comments on commit c926886

Please sign in to comment.