middleman / middleman

Hand-crafted frontend development
https://middlemanapp.com
MIT License
7.04k stars 746 forks source link

unable to get less to work with the asset pipeline #1083

Closed holden closed 9 years ago

holden commented 10 years ago

I'm using bower to manage bootstrap and other libraries and most everything i need works beautifully using:

after_configuration do
  sprockets.append_path File.join "#{root}", "components"
....

This works fine when I just want to require something from all.css

 *= require bootstrap

Works great, but when I try to import libraries in less it can't seem to find them anywhere...

// bootstrap_and_overrides.less
// physical location is /components/bootstrap/less
@import "bootstrap/less/bootstrap";
@import "bootstrap";

Nothing works, cannot find assets error... I'm not sure what I'm doing wrong.

https://github.com/razorfly/middleman-bootstrap-template

tdreyno commented 10 years ago

Does less support Sprockets?

holden commented 10 years ago

I do believe so, they mention it specifically here: https://github.com/sstephenson/sprockets

Also, it works fine with Rails when I do similar things, just can't get it to work similarly here.

bhollis commented 10 years ago

I don't think we do anything special to put them together - I'm guessing there's a less-rails around somewhere that we'd need to pick glue code out of.