Django with compass

246 views
Skip to first unread message

Andrés gutiérrez

unread,
Nov 7, 2010, 12:57:45 PM11/7/10
to compas...@googlegroups.com
Today what is the best way to work with compass in a Django project. I have find those app [1] , [2] and [3]
But i would like to know if is other ways to work with compass without additional software?

Someone has made a step to step tutorial? i have read this [4] but don't explain how/where comfigure Django to work with Compass

Eric Meyer use Django with Compass + Susy in susy's website. I would like to use this tools too. But i don't find any resource to do it without add-ons [1], [2] or [3]


[1] http://bitbucket.org/zacharyvoase/django-compass
[2] https://github.com/drewyeaton/django-orienteer
[3] https://github.com/policus/graphpaper
[4] http://www.feedmagnet.com/blog/grid-design-with-sass/

Andrés gutiérrez

unread,
Nov 7, 2010, 1:58:15 PM11/7/10
to compas...@googlegroups.com
I'm reading documentation of compass and making some trials.

if i run this:
compass -r susy -f susy <my_project>
I get a deprecated WARNIG:
WARNING: This interface is deprecated. Please use the new subcommand interface.
See `compass help` for more information.

wel, reading docs i understant that with compass 10.5 i have to make this:
compass create <my_project> --using FRAMEWORK

if i list the available frameworks i get this:
Available Frameworks & Patterns:

  * blueprint
    - blueprint/basic      - A basic blueprint install that mimics the actual blueprint css.
    - blueprint/buttons    - Button Plugin
    - blueprint/link_icons - Icons for common types of links
    - blueprint/project    - The blueprint framework.
    - blueprint/semantic   - The blueprint framework for use with semantic markup.
  * compass
    - compass/ellipsis     - Plugin for cross-browser ellipsis truncated text.
    - compass/extension    - Generate a compass extension.
    - compass/project      - The default project layout.


My question is: Susy is a FRAMEWORK? How can i create a compass project inside a Django project and use Susy?

Andrés gutiérrez

unread,
Nov 7, 2010, 2:20:48 PM11/7/10
to compas...@googlegroups.com

Sorry for the question. That is the way i have found:

compass create sass --using susy -r susy -x sass

Eric Meyer

unread,
Nov 8, 2010, 2:47:07 PM11/8/10
to Compass
Andres,

We are using Compass with Django, but without any specific integration
between the two. We compile the sass code locally, and check both the
sass and css into our version control. This is not the way Chris
recommends, but it works best for our needs. I'm not sure how all the
Ruby integrations work, so I can't say exactly how are method compares
to that. If you have more questions on the Django end, I can put you
in touch with Carl, who handles all our back-end code.

Cheers,
Eric



On Nov 7, 1:20 pm, Andrés gutiérrez <andresgut...@gmail.com> wrote:
> El 7 de noviembre de 2010 19:58, Andrés gutiérrez
> <andresgut...@gmail.com>escribió:

Andrés gutiérrez

unread,
Nov 9, 2010, 4:09:32 AM11/9/10
to compas...@googlegroups.com


2010/11/8 Eric Meyer <erii...@gmail.com>

Andres,

We are using Compass with Django, but without any specific integration
between the two. We compile the sass code locally, and check both the
sass and css into our version control. This is not the way Chris
recommends, but it works best for our needs. I'm not sure how all the
Ruby integrations work, so I can't say exactly how are method compares
to that. If you have more questions on the Django end, I can put you
in touch with Carl, who handles all our back-end code.

No, that did the work for me:

compass create sass --using susy -r susy -x sass 

Now i have a dir with compass config inside Django proyect.

But i don't know how to change image and js folders:

that is my scenario:

project_root
   |--site_media
     |--img
     |--css
     |--js
     |--sass
        |--sass_files
        |--compiled_css
        |--images
        |--config.rb

Inside my config.rb i try to change my 

image_dir = ../img

But that don't work.

Many thanks for your help and for Susy


--
You received this message because you are subscribed to the Google Groups "Compass" group.
To post to this group, send email to compas...@googlegroups.com.
To unsubscribe from this group, send email to compass-user...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/compass-users?hl=en.


Steve Schwarz

unread,
Nov 9, 2010, 8:08:28 AM11/9/10
to compas...@googlegroups.com
2010/11/9 Andrés gutiérrez <andres...@gmail.com>

Now i have a dir with compass config inside Django proyect.

But i don't know how to change image and js folders:

that is my scenario:

project_root
   |--site_media
     |--img
     |--css
     |--js
     |--sass
        |--sass_files
        |--compiled_css
        |--images
        |--config.rb

Inside my config.rb i try to change my 

image_dir = ../img

But that don't work.

Many thanks for your help and for Susy
Hi,
For my Django projects I put my sass directory in the root of the project and the config.rb in the root of the project. To me it is "source" that I don't want in my site_media. Then my config.rb has paths that are at the same level or below it in the directory hierarchy.
Best Regards,
Steve
http://tech.agilitynerd.com/

Andrés gutiérrez

unread,
Nov 9, 2010, 8:17:49 AM11/9/10
to compas...@googlegroups.com


2010/11/9 Steve Schwarz <agili...@gmail.com>
Thanks i'll try that
Best Regards,
Steve
http://tech.agilitynerd.com/

--

Drew Yeaton

unread,
Nov 9, 2010, 1:57:59 PM11/9/10
to Compass
If you use django-orienteer (checkout [2] above) you could do this and
you wouldn't need to run compass watch while you develop. This is more
or less the reason I made it.

FWIW, at Gowalla we use Sass but run a script locally that uses
FSEvents to watch for changes and compiles if necessary. In Git we
ignore the generated CSS and track the Sass. Also, when we deploy a
script generates CSS from the source on the server.

On Nov 9, 7:08 am, Steve Schwarz <agilityn...@gmail.com> wrote:
> 2010/11/9 Andrés gutiérrez <andresgut...@gmail.com>

Andrés gutiérrez

unread,
Nov 9, 2010, 2:04:51 PM11/9/10
to compas...@googlegroups.com


2010/11/9 Drew Yeaton <xee...@gmail.com>

If you use django-orienteer (checkout [2] above) you could do this and
you wouldn't need to run compass watch while you develop. This is more
or less the reason I made it.

FWIW, at Gowalla we use Sass but run a script locally that uses
FSEvents to watch for changes and compiles if necessary. In Git we
ignore the generated CSS and track the Sass. Also, when we deploy a
script generates CSS from the source on the server.

Sound good. But for the moment i'll made the basic with compass wacth and the css generated only on development.

Markus Gattol

unread,
Nov 22, 2010, 9:57:46 AM11/22/10
to Compass
Have a look at http://www.allbuttonspressed.com/blog/django/2010/08/Using-Sass-with-django-mediagenerator

This does the .sass to .css for you automatically and integrates
nicely into Django

Andrés gutiérrez

unread,
Nov 22, 2010, 10:57:21 AM11/22/10
to compas...@googlegroups.com


2010/11/22 Markus Gattol <markus...@gmail.com>

Have a look at http://www.allbuttonspressed.com/blog/django/2010/08/Using-Sass-with-django-mediagenerator

This does the .sass to .css for you automatically and integrates
nicely into Django

Thanks sound great
Reply all
Reply to author
Forward
0 new messages