Sha256: 725438280c591793c6ca3253748d900bd3ef73da1984969418ed9c71f47b4a4e

Contents?: true

Size: 496 Bytes

Versions: 51

Compression:

Stored size: 496 Bytes

Contents

namespace :datagrid do

  desc "Copy table partials into rails application"
  task :copy_partials do
    require "fileutils"
    views_path = "app/views/datagrid"
    destination_dir = (Rails.root + views_path).to_s
    pattern = File.expand_path(File.dirname(__FILE__) + "/../../#{views_path}") + "/*"
    Dir[pattern].each do |template|
      puts "* copy #{template} => #{destination_dir}"
      FileUtils.mkdir_p destination_dir
      FileUtils.cp template, destination_dir
    end
  end
end

Version data entries

51 entries across 51 versions & 1 rubygems

Version Path
datagrid-1.8.2 lib/tasks/datagrid_tasks.rake
datagrid-1.8.1 lib/tasks/datagrid_tasks.rake
datagrid-1.8.0 lib/tasks/datagrid_tasks.rake
datagrid-1.7.0 lib/tasks/datagrid_tasks.rake
datagrid-1.6.3 lib/tasks/datagrid_tasks.rake
datagrid-1.6.2 lib/tasks/datagrid_tasks.rake
datagrid-1.6.1 lib/tasks/datagrid_tasks.rake
datagrid-1.6.0 lib/tasks/datagrid_tasks.rake
datagrid-1.5.9 lib/tasks/datagrid_tasks.rake
datagrid-1.5.8 lib/tasks/datagrid_tasks.rake
datagrid-1.5.7 lib/tasks/datagrid_tasks.rake
datagrid-1.5.6 lib/tasks/datagrid_tasks.rake
datagrid-1.5.5 lib/tasks/datagrid_tasks.rake
datagrid-1.5.4 lib/tasks/datagrid_tasks.rake
datagrid-1.5.3 lib/tasks/datagrid_tasks.rake
datagrid-1.5.2 lib/tasks/datagrid_tasks.rake
datagrid-1.5.1 lib/tasks/datagrid_tasks.rake
datagrid-1.5.0 lib/tasks/datagrid_tasks.rake
datagrid-1.4.4 lib/tasks/datagrid_tasks.rake
datagrid-1.4.3 lib/tasks/datagrid_tasks.rake