lib/xmvc/builder.rb in xmvc-0.1.2 vs lib/xmvc/builder.rb in xmvc-0.1.3
- old
+ new
@@ -8,12 +8,11 @@
case name
when :setup
setup(options)
else
begin
- @jammit = jammit(options)
- @jammit.invoke(:build, [name])
+ Xmvc.asset_mgr(options).invoke(:build, [name])
rescue Jammit::Error => e
raise Xmvc::BuilderError.new(e.message)
end
end
end
@@ -34,11 +33,11 @@
}
options[:vendors].each do |vendor|
javascripts.update(vendor["name"] => vendor_assets("javascripts", vendor))
end
- jammit = Jammit::CLI.new([], options)
+ jammit = Xmvc.asset_mgr(options)
jammit.invoke(:init)
jammit.invoke(:config, ["set", "javascripts", javascripts])
jammit.invoke(:build)
rescue Jammit::Error => e
@@ -50,13 +49,9 @@
vendor[type].map {|f| File.join("vendor", vendor["name"], f) }
end
def application_assets(type, assets)
assets.map {|f| File.join(f)}
- end
-
- def jammit(options={})
- Jammit::CLI.new([], options)
end
end
end
end
\ No newline at end of file