Setting a system property in Gradle

‹ What is Groovy? | Upgrading Gradle to the latest version on Ubuntu ›

Java system properties can be specified in Gradle by creating a file in one of these locations:

  • $HOME/.gradle/

And creating a property name that's prefixed with systemProp. For example, to set a system property called appengine.sdk.root, you'd create a file with this contents:


Putting the file in $SUBPROJECT_DIR/ does not appear to work.

Subscribe to All Posts - Wesley Tanaka