Sha256: 326067f83a1a01f4e5198a0002d7d896c7db7ddd0a58c5750cd9f3e9ae03f7f2

Contents?: true

Size: 574 Bytes

Versions: 6

Compression:

Stored size: 574 Bytes

Contents

# based on https://www.tomdooner.com/2014/06/29/webpack.html
require 'rake'

Rake::Task['assets:precompile'].enhance(['assets:compile_environment'])

namespace :assets do
  # set prerequisites for the assets:precompile task
  task :compile_environment => :build_external_assets do
    Rake::Task['assets:environment'].invoke
  end

  desc 'Build external assets'
  task :build_external_assets do
    sh "NODE_ENV=#{Rails.env} #{RailsExternalAssets.config.build_script}"
  end

  task :clobber do
    rm_rf File.join('public', RailsExternalAssets.config.base_path)
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
rails_external_assets-0.6.0 lib/rails_external_assets/tasks/assets.rake
rails_external_assets-0.5.0 lib/rails_external_assets/tasks/assets.rake
rails_external_assets-0.4.0 lib/rails_external_assets/tasks/assets.rake
rails_external_assets-0.3.1 lib/rails_external_assets/tasks/assets.rake
rails_external_assets-0.3.0 lib/rails_external_assets/tasks/assets.rake
rails_external_assets-0.2.0 lib/rails_external_assets/tasks/assets.rake