Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
tree: 2d907ad207
Fetching contributors…

Cannot retrieve contributors at this time

35 lines (30 sloc) 0.944 kB
require "rake-pipeline/middleware"
module Rake
class Pipeline
# Use Rake::Pipeline inside of Rails 3.x. To use, simply add
# Rake::Pipeline to your +Gemfile+:
#
# !!!ruby
# gem 'rake-pipeline'
#
# Then, activate it in development mode. In config/development.rb:
#
# !!!ruby
# config.rake_pipeline_enabled = true
#
class Railtie < ::Rails::Railtie
config.rake_pipeline_enabled = false
config.rake_pipeline_assetfile = 'Assetfile'
rake_tasks do
load "rake-pipeline/precompile.rake"
end
initializer "rake-pipeline.assetfile" do |app|
if config.rake_pipeline_enabled
assetfile = File.join(Rails.root, config.rake_pipeline_assetfile)
project = Rake::Pipeline::Project.new assetfile
config.app_middleware.insert ActionDispatch::Static, Rake::Pipeline::Middleware, project
end
end
end
end
end
Jump to Line
Something went wrong with that request. Please try again.