Class: RailsLens::RakeBootstrapper

Inherits:
Object
  • Object
show all
Defined in:
lib/rails_lens/rake_bootstrapper.rb

Class Method Summary collapse

Class Method Details

.callObject



6
7
8
9
10
11
12
13
14
15
# File 'lib/rails_lens/rake_bootstrapper.rb', line 6

def call
  require 'rake'
  load './Rakefile' if File.exist?('./Rakefile') && !Rake::Task.task_defined?(:environment)

  begin
    Rake::Task[:environment].invoke
  rescue StandardError
    nil
  end
end