Compass cannot find Sprite folder

For some reason, Compass cannot find this folder that I configured for sprites. This is what my catalogs look like.

Project
   media
      compass
         sass
            modules
               _module.scss
            style.scss
         config.rb
      images
         sprites
             button_hover.jpg
             button_active.jpg
             button.jpg

And inside my config.rb file, I have setup_dir setup ../ images. The errors that occur when trying to import ( @import '../images/sprites/button*.jpg') files inside _module.scss are mainly as follows:

File to import not found or unreadable: images/sprites/button*.jpg.

Not sure what is going on.

+3
source share
4 answers

Compass sprites are PNG only. No JPG afaik.

+11
source

Well, if styles.scss is in the format media / compass / sass and images in media / then you need to do ../../instead of ../no?

+2
source

0.12.2 png C:\Ruby193\lib\ruby\gems\1.9.1\gems\compass-0.12.2\lib\compass\sprite_importer.rb

19:

-      Dir.glob(File.join(path, "**", glob))
+      Sass::Util.glob(File.join(path, "**", glob))

78:

-        files = Dir[File.join(folder, uri)].sort
+        files = Sass::Util.glob(File.join(folder, uri)).sort

: https://github.com/chriseppstein/compass/commit/58babac01b56eddf63bac737f7f781d98f00f6b9

+1

configure your config.rb. then the compass will know where to find your images;)

and the compass only works with png.

0
source

All Articles