Closed shamrt closed 11 years ago
Try something like import "app/css/base" as the SASS import relative path might be the app.rb and not your current scss file
No change.
Given that this issue can be created with the sinatra-assetpack
repository examples, I am interested to see whether it can be reproduced by another party. As aforesaid, the only difference between the pristine repository and what I am attempting to do is the addition of @import "base";
(and its corresponding SCSS partial file) to main.scss
.
I should mention that adding c.sass_dir = "app/css"
to app.rb
makes no difference. And, once again, the stack trace indicates that the app load path is missing, which strikes me as bizarre.
Look at your load paths at the top of that stacktrace @shamrt. You'll need something like this in your assets
configuration:
assets {
set :scss, { :load_paths => Compass.sass_engine_options[:load_paths] + [ "#{settings.root}/app/css" ] }
# the rest
}
Thank-you, @bentruyman, that suggestion worked --- with some caveats, which are explained in a gist, in case anyone else runs into this issue and is as befuddled as I was.
Great gist. Hope others find it too.
Attempting to import a SASS partial file via
main.scss
in your Compass example leads to a 500 error.Adding the line
@import "base";
returns the following stack trace:This appears to be a problem of not setting the appropriate load path for Compass.