aboutsummaryrefslogtreecommitdiffstats
path: root/actioncable/Rakefile
diff options
context:
space:
mode:
authorJon Moss <me@jonathanmoss.me>2016-01-30 20:39:22 -0500
committerJon Moss <me@jonathanmoss.me>2016-01-30 20:44:42 -0500
commit09a706065952d58d515420b19a55df619eb7f53d (patch)
tree422b1b5473e7784c56e9a8f5a2bf070a86b87530 /actioncable/Rakefile
parent896950a605c509f19f3e8cbde11e23ca87036ca3 (diff)
downloadrails-09a706065952d58d515420b19a55df619eb7f53d.tar.gz
rails-09a706065952d58d515420b19a55df619eb7f53d.tar.bz2
rails-09a706065952d58d515420b19a55df619eb7f53d.zip
Improvements and reorganization of assets
Diffstat (limited to 'actioncable/Rakefile')
-rw-r--r--actioncable/Rakefile10
1 files changed, 8 insertions, 2 deletions
diff --git a/actioncable/Rakefile b/actioncable/Rakefile
index 9ba431f8a9..0a036e3e3d 100644
--- a/actioncable/Rakefile
+++ b/actioncable/Rakefile
@@ -19,10 +19,13 @@ end
namespace :assets do
desc "Compile dist/action_cable.js"
task :compile do
+ puts 'Compiling Action Cable assets...'
+
asset_mapping = { "source.js" => "action_cable.js" }
root_path = Pathname.new(dir)
- load_path = root_path.join("lib/assets/javascripts/action_cable")
+ load_path = root_path.join("app/assets/javascripts/action_cable")
+ destination_path = root_path.join("lib/assets/javascripts")
compile_path = root_path.join("tmp/sprockets")
compile_path.rmtree if compile_path.exist?
@@ -36,7 +39,10 @@ namespace :assets do
asset_mapping.each do |logical_path, dist_path|
fingerprint_path = manifest.assets[logical_path]
- FileUtils.cp(compile_path.join(fingerprint_path), load_path.join("dist/#{dist_path}"))
+ FileUtils.cp(compile_path.join(fingerprint_path), destination_path.join(dist_path))
end
+
+ puts '======'
+ puts 'Action Cable assets compiled successfully!'
end
end