grailsgradleggts

where is gradle properties file located in gradle project?


Where does the gradle.properties file located in Grails/Gradle project? I tried but not able to find it. I have build the Gradle project using command line. and what is the major purpose of that file.


Solution

  • There are 2 possible location for gradle.properties file:

    1. project build dir
    2. gradle user home

    Note, gradle.properties file is not necessary located within your projects files. If it's absent, look for it in your gradle user home directory (as in users guide said: it's defined by the GRADLE_USER_HOME environment variable, which if not set defaults to USER_HOME/.gradle).

    It's used to configure Java process, used to build your project.

    You can read more about it in the Gradle official user guide