3

1 The Problem:

I use sass (scss) + compass in my project.

At first, I just use command line to watch, i.e. "Compass watch" and everything works well.

Yesterday, I start to use Codekit to auto-compile all my files, with exactly the same style.scss file, it error out.

1.1 Some Detail:

I use compass to create image sprites, so in my .scss file I have two line:

@import "contact/*.png";
@include all-contact-sprites;

contact folder is where i put all the .png images, It works well with command line "compass watch", no error at all, yet when I use Codekit, it keep erroring out.

1.2 The error image:

"Syntax error: File to import not found or unreadable" enter image description here

P.S. As a newbie, I know it's my problem, and I know it's somekind a stupid question, but after hours searching, I still get nowhere, so I post this question.

Community
  • 1
  • 1
Alex G
  • 1,321
  • 1
  • 24
  • 31

1 Answers1

5

It seems like CodeKit is trying to compile with SASS, while @import "contact/*.png" is a feature of Compass.

Make sure you point CodeKit at the root of your project where config.rb resides. Refer to CodeKit documentation.

Andrey Mikhaylov - lolmaus
  • 23,107
  • 6
  • 84
  • 133
  • 1
    CodeKit detect if compass is installed by looking for config.rb in the root folder. This is not very convenient, since not all projects start in the root folder. For now, to get it working, just delete the project from CodeKit and add the subfolder into it again. This will make CodeKit work. – windmaomao Nov 24 '14 at 21:21