Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 4243020
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 21, 20262026-05-21T03:31:17+00:00 2026-05-21T03:31:17+00:00

I have done compass create . and compass init rails whilst in my project

  • 0

I have done compass create . and compass init rails whilst in my project directory. A few questions:

  • I have placed my .sass files in public/stylesheets. Is this the right place to put them?
  • When I run compass watch, it does not automatically compile these .sass files. I have to manually specify the files: compass watch public/stylesheets/myfile.sass etc. How do I get this working automatically?
  • The files ie.css, print.css and screen.css have been placed in stylesheets/compiled. How do I remove these without them reappeareing after compilation?
  • My own compiled .sass files are compiled to compiled/ts. Why are they in ts and not in compiled?

Many thanks in advance


Edit: Worked it out:

  • No, put them in app/stylesheets/
  • Works if you follow above
  • Remove them from app/stylesheets/
  • Do first answer and they will be put in compiled/
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-21T03:31:17+00:00Added an answer on May 21, 2026 at 3:31 am

    Compass uses a configuration file located in “config/compass.rb” which tells it where the important directories are. I think it knows to look in config/compass.rb because it searches a list of predefined directories for a compass.rb config file

    Heres the config file I use for my Rails 3 projects

    # This configuration file works with both the Compass command line tool and within Rails.
    # Require any additional compass plugins here.
    project_type = :rails
    project_path = Compass::AppIntegration::Rails.root
    # Set this to the root of your project when deployed:
    http_path = "/"
    css_dir = "public/stylesheets"
    sass_dir = "app/stylesheets"
    images_dir = "public/images"
    environment = Compass::AppIntegration::Rails.env
    # To enable relative paths to assets via compass helper functions. Uncomment:
    # relative_assets = true
    preferred_syntax = :sass
    

    I generate this file by running the following command from the Rails root:

    compass init rails --css-dir=public/stylesheets --sass-dir=app/stylesheets --images-dir=public/images -x sass --using blueprint/basic
    

    This is the only command that I use to run compass, and I run it when generating my project through a rails template https://github.com/sid137/rails-templates/blob/master/rails3.rb . I constructed this command by reading through the compass help, and looking online, as I wanted to customize all of my compass setup. Now, I can immediately begin my projects with

    compass watch .
    

    or

    compass compile .
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have done a few projects using Ruby on Rails. I am going to
I have done porting of a c++ project with gtest tests to a c#
i have done some pages with Struts 2.(J2EE project) All was ok until i
I have done a web project ( using C# + SQL CE + ASP.NET
I have done one project in android which is to display map using GOOGLE
I have done one full project using WPF, and have (at least) a pretty
I have one requirement: copy local files to remote system. I have done the
I have done Java and JSP programming in the past, but I am new
I have done a bit of testing on this myself (During the server side
I have done a bit of research into this and it seems that the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.