Skip to content
Leiningen plugin to compile haml files
Clojure CSS
Branch: master
Clone or download
Pull request Compare This branch is 11 commits ahead, 5 commits behind stephanos:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.

lein-sass Build Status

Leiningen plugin to compile SASS/SCSS files with SassC or Sass.

Clojars Project


You can install the plugin by adding lein-sass to your project.clj file in the plugins section:

(defproject example "1.0.0"
  :plugins [[lein-sass "0.4.0"]])

SassC needs to be installed manually. For example on OSX run brew install sassc.

To install SassC on Ubuntu (should similarly apply to other Unixes) I usually follow this recipe:

Alternatively you can use sass to compile your sass or scss files. This needs to be installed as well, but the process might be straight forward. Please see for install instructions.

On a Linux system you can just run sudo gem install sass (provided a decent Ruby runtime is installed).


Here is an example of project.clj with all the possible definitions.

(defproject example-project "1.2.3"

  :sass {:src "resources/sass"
         :output-directory "resources/public/css"

         ;; other options (provided are default values):
         ;; :delete-output-dir true
         ;; :source-maps true
         ;; :style :nested
         ;; :command :sassc (:sass or :sassc are recognized values)


To compile your files once:

$ lein sass once

To keep the compiler running and watch for changes:

$ lein sass auto

To delete all the files generated by lein-sass

$ lein sass clean


The following hooks are supported by lein-sass:

$ lein compile
$ lein clean

To enable the hooks, add the following to your project.clj file:

:hooks [leiningen.sass]


Copyright (C) 2013 Renaud Tircher, 2014 Stephan Behnke

Distributed under the Eclipse Public License, the same as Clojure.

You can’t perform that action at this time.