Sha256: 996008ab2964f6ec5ddfd56b1ebe6b34255cd3ecab1757c19845b1cfae0a2e22

Contents?: true

Size: 467 Bytes

Versions: 12

Compression:

Stored size: 467 Bytes

Contents

module Rails3::Assist::File
  module Environment
    def insert_before_application_init content=nil, &block
      insert_application_init :before, content, &block
    end

    def insert_after_application_init content=nil, &block
      insert_application_init :after, content, &block
    end

    def insert_application_init place, statement=nil, &block
      File.insert_into environment_file, statement, place => /\w+::Application.initialize!/
    end    
  end
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
rails3_assist-0.3.3 lib/rails3_assist/file/environment.rb
rails3_assist-0.3.2 lib/rails3_assist/file/environment.rb
rails3_assist-0.3.1 lib/rails3_assist/file/environment.rb
rails3_assist-0.3.0 lib/rails3_assist/file/environment.rb
rails3_assist-0.2.13 lib/rails3_assist/file/environment.rb
rails3_assist-0.2.12 lib/rails3_assist/file/environment.rb
rails3_assist-0.2.11 lib/rails3_assist/file/environment.rb
rails3_assist-0.2.10 lib/rails3_assist/file/environment.rb
rails3_assist-0.2.9 lib/rails3_assist/file/environment.rb
rails3_assist-0.2.8 lib/rails3_assist/file/environment.rb
rails3_assist-0.2.7 lib/rails3_assist/file/environment.rb
rails3_assist-0.2.5 lib/rails3_assist/file/environment.rb