metamaps--metamaps/lib/tasks/extensions.rake

16 lines
426 B
Ruby
Raw Normal View History

2016-09-24 03:00:46 +00:00
# frozen_string_literal: true
namespace :assets do
task :js_compile do
2016-09-24 03:00:46 +00:00
system 'npm install'
system 'npm run build'
2017-10-14 19:02:41 +00:00
end
task :production_ready do
2016-10-04 15:43:42 +00:00
system 'bin/build-apidocs.sh' if Rails.env.production?
2017-10-14 19:02:41 +00:00
Rake::Task['perms:fix'].invoke if Rails.env.production?
end
end
Rake::Task[:'assets:precompile'].enhance([:'assets:js_compile'])
2017-10-14 19:02:41 +00:00
Rake::Task[:'assets:precompile'].enhance([:'assets:production_ready'])