Question

I was using Sass on an existing site and decided to get Compass up and running on Win7x64. Ruby, HAML, Compass all installed fine (afaik).

I have a project at c:\project with a static files served out of c:\project\static with a directory structure that has to stay the same. I went into c:\project\static and ran this:

compass create css-compass

This resulted in the following dir structure

c:\project\static\css (previously existed; output css)
c:\project\static\css-sass (previously existed; source css)
c:\project\static\css-compass (the new compass dir created by compass)    

And here is my config.rb:

# Require any additional compass plugins here.
# Set this to the root of your project when deployed:
http_path = "/"
css_dir = "..\\css"
sass_dir = "..\\css-sass"
images_dir = "images"
javascripts_dir = "javascripts"

When I go to c:\project\static and run compass watch compass-css, I get the following error:

Nothing to compile. If you're trying to start a new project, you have left off the directory argument. Run "compass -h" to get help.

However, if I create symlinks inside c:\project\static\css-compass from css->..\css and css-sass => ..\css-sass then everything works just fine.

What the what?

Was it helpful?

Solution

facepalm

Apparently you need to set relative_assets = true in your config.rb file. Why this isn't the default is beyond me. Oh well!

OTHER TIPS

im late :-)

You can also use relative Path's in project_path

Example

project_path    = "../src/main/webapp/"

More Details in this Answer: Can't make grunt-contrib-compass work

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top