I have a gradle build script into which I am trying to include Eric Wendelin\'s css plugin - http://eriwen.github.io/gradle-css-plugin/
Its easy enough to implement,
You should consider passing the -P argument in invoking Gradle.
From Gradle Documentation :
--project-prop Sets a project property of the root project, for example -Pmyprop=myvalue. See Section 14.2, “Gradle properties and system properties”.
Considering this build.gradle
task printProp << {
println customProp
}
Invoking Gradle -PcustomProp=myProp will give this output :
$ gradle -PcustomProp=myProp printProp
:printProp
myProp
BUILD SUCCESSFUL
Total time: 3.722 secs
This is the way I found to pass parameters.