Sha256: 7e4e5773799dd925b2d3da34177b6647ec32c0113d6ad26e269f5e0c532c9a58

Contents?: true

Size: 663 Bytes

Versions: 17

Compression:

Stored size: 663 Bytes

Contents

# frozen_string_literal: true

require 'rails'

%w[version configuration table_definition methods scopes base].each do |file_name|
  require "active_archive/#{file_name}"
end

require 'generators/active_archive/install_generator'

module ActiveArchive
  class Railtie < ::Rails::Railtie

    initializer 'active_archive' do |app|
      ActiveArchive::Railtie.instance_eval do
        [app.config.i18n.available_locales].flatten.each do |locale|
          (I18n.load_path << path(locale)) if File.file?(path(locale))
        end
      end
    end

    def self.path(locale)
      File.expand_path("../../config/locales/#{locale}.yml", __FILE__)
    end

  end
end

Version data entries

17 entries across 17 versions & 1 rubygems

Version Path
active_archive-6.1.0 lib/active_archive.rb
active_archive-6.0.2 lib/active_archive.rb
active_archive-6.0.1 lib/active_archive.rb
active_archive-6.0.0 lib/active_archive.rb
active_archive-5.3.0 lib/active_archive.rb
active_archive-5.2.2 lib/active_archive.rb
active_archive-5.2.1 lib/active_archive.rb
active_archive-5.2.0 lib/active_archive.rb
active_archive-5.1.7 lib/active_archive.rb
active_archive-5.1.6 lib/active_archive.rb
active_archive-5.1.5 lib/active_archive.rb
active_archive-5.1.4 lib/active_archive.rb
active_archive-5.1.3 lib/active_archive.rb
active_archive-5.1.2 lib/active_archive.rb
active_archive-5.1.1 lib/active_archive.rb
active_archive-5.1.0 lib/active_archive.rb
active_archive-5.0.0 lib/active_archive.rb