title: Compiling SASS using jRuby
body: <p>I'm using jruby to compile scss files to css using ant build script.</p>
  
  <p><div class="snippet" data-lang="js" data-hide="false">
  <div class="snippet-code">
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
  &lt;project name="test" default="compileSCSS" basedir="."&gt;
      &lt;taskdef resource="net/sf/antcontrib/antlib.xml"&gt;
          &lt;classpath&gt;
              &lt;pathelement location="ant-contrib-1.0b3.jar"/&gt;
          &lt;/classpath&gt;
      &lt;/taskdef&gt;
      &lt;path id="JRuby"&gt;
          &lt;fileset file="libs/jruby-complete-1.7.18.jar"/&gt; &lt;!-- Location of JRuby jar file --&gt;
      &lt;/path&gt; 
      &lt;target name="compileSCSS"&gt;
          &lt;echo message="Compiling scss files..." /&gt;
          &lt;property name="filesIn" value="style.scss" /&gt;
          &lt;property name="fileOutDir" value="output/" /&gt;
          &lt;property name="root" value="." /&gt;
          &lt;script language="ruby" classpathref="JRuby"&gt;
              &lt;![CDATA[
                  require './libs/sass/lib/sass'
                  require './libs/sass/lib/sass/exec'
                  files = Dir.glob($project.getProperty('filesIn'))
                  files.each do |file|
                     opts = Sass::Exec::Sass.new(["--load-path", File.dirname(file), file, File.join($project.getProperty('fileOutDir'), File.basename(file, ".*") + ".css")])
                     opts.parse
                  end
              ]]&gt;
          &lt;/script&gt;
          &lt;echo message="Done compiling SCSS source files." /&gt;
      &lt;/target&gt;
  &lt;/project&gt;</code></pre>
  </div>
  </div>
  </p>
  
  <p>This is my build script. I'm using jruby 1.7.8 and SASS source code from github (version 3.4.9).</p>
  
  <p>Its throwing <strong>exception</strong> :</p>
  
  <pre><code>javax.script.ScriptException: org.jruby.embed.EvalFailedException: 
  (NameError) uninitialized constant Sass::Exec::Sass
  </code></pre>
  
  <p>Please help. What could be the Issue?</p>