Sha256: 39e1f46ed3f7bff758985cf0784a325638f9ba2b9fd0ae15fc08452aaca738ea

Contents?: true

Size: 1.36 KB

Versions: 1

Compression:

Stored size: 1.36 KB

Contents

require 'devise'
require 'cancancan'
require 'omniauth'
require 'omniauth-ldap'
require 'bootstrap-sass'
require 'autoprefixer-rails'
require 'font-awesome-sass'
require 'simple-navigation'
require 'jquery-datatables-rails'
require 'ajax-datatables-rails'
require 'bootstrap_form'
require 'nprogress-rails'
require 'rails-i18n'
require 'momentjs-rails'

require 'simple_navigation_renderers'
SimpleNavigation.config_file_paths << File.expand_path('../../../config', __FILE__)

module Chaltron
  class Engine < ::Rails::Engine
    config.generators do |g|
      g.test_framework :rspec, fixture: false
      g.fixture_replacement :factory_girl, dir: 'spec/factories'
      g.assets false
      g.helper false
    end

    config.app_generators do |g|
      g.templates.unshift File::expand_path('../../templates', __FILE__)
    end

    initializer('chaltron.locales') do |_app|
      Chaltron::Engine.config.i18n.load_path += Dir[root.join('app/views', 'locales', '*.{rb,yml}')]
      Chaltron::Engine.config.i18n.load_path += Dir[root.join('app/models', 'locales', '*.{rb,yml}')]
    end

    initializer('chaltron.helpers') do |_app|
      ActiveSupport.on_load(:action_controller) do
        include Chaltron::Controllers::Helpers

        puts '--------------------------DEBUG'

        before_action :configure_permitted_parameters, if: :devise_controller?
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
chaltron-0.1.2 lib/chaltron/engine.rb~