Sha256: 6fabd2c335844e8f58bf9d4e3465135ce7e5b072037f698579bca97a15184c93

Contents?: true

Size: 756 Bytes

Versions: 35

Compression:

Stored size: 756 Bytes

Contents

module WatCatcher
  class Railtie < ::Rails::Railtie

    config.before_initialize do
      # Configure bugsnag rails defaults
      WatCatcher.configure do |config|
        config.logger = ::Rails.logger
        config.release_stage = ::Rails.env.to_s
        config.project_root = ::Rails.root.to_s
      end

      # Auto-load configuration settings from config/bugsnag.yml if it exists
      config_file = ::Rails.root.join("config", "wat_catcher.yml")
      config = YAML.load_file(config_file) if File.exists?(config_file)
      WatCatcher.configure(config[::Rails.env] ? config[::Rails.env] : config) if config

   end
    initializer "wat_catcher.view_helpers" do |app|
      ActionView::Base.send :include, ::WatCatcher::Helper
    end

  end

end

Version data entries

35 entries across 35 versions & 1 rubygems

Version Path
wat_catcher-0.10.1 lib/wat_catcher/railtie.rb
wat_catcher-0.10.0 lib/wat_catcher/railtie.rb
wat_catcher-0.9.0 lib/wat_catcher/railtie.rb
wat_catcher-0.8.9 lib/wat_catcher/railtie.rb
wat_catcher-0.8.8 lib/wat_catcher/railtie.rb
wat_catcher-0.8.7 lib/wat_catcher/railtie.rb
wat_catcher-0.8.6 lib/wat_catcher/railtie.rb
wat_catcher-0.8.5 lib/wat_catcher/railtie.rb
wat_catcher-0.8.4 lib/wat_catcher/railtie.rb
wat_catcher-0.8.3 lib/wat_catcher/railtie.rb
wat_catcher-0.8.2 lib/wat_catcher/railtie.rb
wat_catcher-0.8.1 lib/wat_catcher/railtie.rb
wat_catcher-0.8.0 lib/wat_catcher/railtie.rb
wat_catcher-0.7.2 lib/wat_catcher/railtie.rb
wat_catcher-0.7.1 lib/wat_catcher/railtie.rb
wat_catcher-0.7.0 lib/wat_catcher/railtie.rb
wat_catcher-0.6.0 lib/wat_catcher/railtie.rb
wat_catcher-0.5.5 lib/wat_catcher/railtie.rb
wat_catcher-0.5.4 lib/wat_catcher/railtie.rb
wat_catcher-0.5.3 lib/wat_catcher/railtie.rb