summaryrefslogtreecommitdiff
path: root/lib/tasks/dev.rake
blob: 0488f26318a17b9c9fb65e47c731b198433e5284 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
task dev: ["dev:setup"]

namespace :dev do
  desc "GitLab | Setup developer environment (db, fixtures)"
  task setup: :environment do
    ENV['force'] = 'yes'
    Rake::Task["gitlab:setup"].invoke

    # Make sure DB statistics are up to date.
    ActiveRecord::Base.connection.execute('ANALYZE')

    Rake::Task["gitlab:shell:setup"].invoke
  end

  desc "GitLab | Eager load application"
  task load: :environment do
    Rails.configuration.eager_load = true
    Rails.application.eager_load!
  end
end