ruhoh / ruhoh.rb

http://ruhoh.com
616 stars 69 forks source link

Sprockets/asset pipeline with Compass #261

Closed waynedpj closed 10 years ago

waynedpj commented 10 years ago

ahoy all,

having trouble getting Ruhoh's asset pipeline working with SASS+Compas as Sprockets needs the Compass paths added, as discussed here.

by adding the following into module Ruhoh::SprocketsPlugin::Compiler.run as suggested here

      # HACK to get Sprockets to find Compass
      env.append_path "#{Gem.loaded_specs['compass'].full_gem_path}/frameworks/compass/stylesheets"

i can get Sprockets to recognize Compass. besides being a hack, it still does not pull in any of the Compass extensions (e.g. Singularity).

is there a clean way to add a path for Sprockets (in general configure Sprockets a bit) in Ruhoh, i.e. via config.yaml, in particular for Compass support? i do not see anything obvious in the code.

thanks, w

plusjade commented 10 years ago

@waynedpj no I didn't spend much time thinking about use-cases like yours. This not to say they are not relevant only that adding sprockets was done in a minimal proof of concept way. I appreciate your work in documenting these problems. I want ruhoh 3.0 to be more like a kind of "toolchain" for static websites. I'm saying this because moving forward, you are right, sprockets integration should be highly decoupled from any ruhoh-specific logic. This would then naturally allow you to customize sprockets (really any asset-pipeline) any way you need to and then have the ruhoh-glue to connect it to your static website.

All this to say I don't have an answer but I want to get a 3.0. alpha out asap so that we can solve these problems at their core.

waynedpj commented 10 years ago

@plusjade sounds good and no worries. some of your recent comments have been indicating this more generic Ruhoh direction and i believe it is a great idea, especially as a tool chain that makes as much as possible configurable (asset pipeline, special collection behavior, maybe even the template system, etc.). i have been looking at Silly in particular and am excited to give it a try and help out with feedback, etc.. i believe it emphasizes one of the things that makes Ruhoh special, i.e. the file system and front matter as a queriable data store. at the same time, i have this project that i still hope to use Ruhoh for so my contributions may be limited while i try to get this finished, either by hacking on Ruhoh 2.x or with 3.0 depending on when it is released and how functional it is out of the gate. regardless, thanks for your work and Ruhoh as always, i am excited for the next iteration.

happy new year.

peace, w