Rakefile 406 B

123456789101112131415
  1. # -*- coding: utf-8 -*-
  2. tasks = -> environment, default_task {
  3. FileList["tasks/#{environment}/**/*.rake"].each(&method(:import))
  4. task :default => default_task
  5. }
  6. case ENV['ENUMERABLE_RB_ENV']
  7. when "development", nil then tasks.call "development", "test"
  8. when "production" then tasks.call "production", "production:run"
  9. else
  10. $stderr.puts "ERROR: there are no tasks for that environment"
  11. exit 1
  12. end