1. See script.groovy for a simple example using a groovy script.

  2. Read about the Gradle Plugin.

  3. Read more about the features, such as math, Config and other.

  4. Follow me on Twitter.

Using Gradle without Plugin

I recommend you use GrooCSS with either the Gradle plugin or asset-pipeline, but it can be used by itself.

    import org.groocss.GrooCSS
    //
    buildscript {
        repositories { jcenter() }
        dependencies { classpath 'org.groocss:groocss:1.0-M2' }
    }
    task css doLast {
        def file = file('css/out.css')
        GrooCSS.process {
            // DSL goes here
        }.writeTo(file)
    }

Using convert methods:

    GrooCSS.convertFile('infile.groocss', 'outfile.css')
    //or
    GrooCSS.convert(new File('in'), new File('out'))


Last updated: 31 July 2019