Sha256: 4611f9283e166e57aa0f5ed3eed9f845471a6cb16e830986ad46a77c4249fed6

Contents?: true

Size: 961 Bytes

Versions: 13

Compression:

Stored size: 961 Bytes

Contents

# frozen_string_literal: true

# Add your own tasks in files placed in lib/tasks ending in .rake,
# for example lib/tasks/capistrano.rake, and they will automatically be available to Rake.

Dir['lib/tasks/*.rake'].each { |rake| load rake }

require 'bundler'
Bundler::GemHelper.install_tasks

require 'rspec/core/rake_task'
RSpec::Core::RakeTask.new(:spec)

task test: :spec

begin
  require 'rubocop/rake_task'
  RuboCop::RakeTask.new
rescue LoadError
  desc 'Run RuboCop'
  task :rubocop do
    warn 'Rubocop is disabled'
  end
end

task default: %i[spec rubocop]

namespace :vendorize do
  desc 'Tasks for vendorizing assets'

  task :flatpickr do
    Dir.chdir(__dir__)
    flatpickr = File.read('node_modules/flatpickr/dist/flatpickr.js')
    locales = Dir.glob('node_modules/flatpickr/dist/l10n/*.js').map { |f| File.read(f) }
    File.write('vendor/assets/javascripts/rails_admin/flatpickr-with-locales.js', ([flatpickr] + locales).join("\n"))
  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
rails_admin-3.3.0 Rakefile
rails_admin-3.2.1 Rakefile
rails_admin-3.2.0 Rakefile
rails_admin-3.2.0.rc Rakefile
rails_admin-3.2.0.beta Rakefile
rails_admin-3.1.4 Rakefile
rails_admin-3.1.3 Rakefile
rails_admin-3.1.2 Rakefile
rails_admin-3.1.1 Rakefile
rails_admin-3.1.0 Rakefile
rails_admin-3.1.0.rc2 Rakefile
rails_admin-3.1.0.rc Rakefile
rails_admin-3.1.0.beta Rakefile