Sha256: ef6e3f461e24c549959f072a2b6d0f85967cf25d9574f508037b01fee142b919

Contents?: true

Size: 605 Bytes

Versions: 8

Compression:

Stored size: 605 Bytes

Contents

require 'rails/generators'

module Bootstrap
  module Generators
    class InstallGenerator < ::Rails::Generators::Base

      source_root File.expand_path("../templates", __FILE__)
      desc "This generator installs Twitter Bootstrap locale"

      def add_locale
        if File.exist?("config/locales/en.bootstrap.yml")
          localez = File.read("config/locales/en.bootstrap.yml")
          insert_into_file "config/locales/en.bootstrap.yml", localez, :after => "en\n"
        else
          copy_file "en.bootstrap.yml", "config/locales/en.bootstrap.yml"
        end
      end

    end
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
bootstrap-sass-extras-0.1.0 lib/generators/bootstrap/install/install_generator.rb
bootstrap-sass-extras-0.0.7 lib/generators/bootstrap/install/install_generator.rb
bootstrap-sass-extras-0.0.6 lib/generators/bootstrap/install/install_generator.rb
bootstrap-sass-extras-0.0.5 lib/generators/bootstrap/install/install_generator.rb
bootstrap-sass-extras-0.0.4 lib/generators/bootstrap/install/install_generator.rb
bootstrap-sass-extras-0.0.3 lib/generators/bootstrap/install/install_generator.rb
bootstrap-sass-extras-0.0.2 lib/generators/bootstrap/install/install_generator.rb
bootstrap-sass-extras-0.0.1 lib/generators/bootstrap/install/install_generator.rb