Gradle System Properties: Difference between revisions
Jump to navigation
Jump to search
Line 10: | Line 10: | ||
==<tt>org.gradle.daemon</tt>== | ==<tt>org.gradle.daemon</tt>== | ||
==<tt>org.gradle.debug</tt>== | ==<tt>org.gradle.debug</tt>== | ||
Starts Gradle in debug mode with the JVM listening on port 5005. Used together with --no-daemon. For more details see: {{Internal|Gradle_Operations#External_Gradle_Process|Gradle Operations | Debug a Gradle Build | External Gradle Process}} | Starts Gradle in debug mode with the JVM listening on port 5005. Used together with [[Gradle_Command_Line#--no-daemon|--no-daemon]]. For more details see: {{Internal|Gradle_Operations#External_Gradle_Process|Gradle Operations | Debug a Gradle Build | External Gradle Process}} | ||
==<tt>org.gradle.jvmargs</tt>== | ==<tt>org.gradle.jvmargs</tt>== |
Revision as of 01:36, 28 March 2021
Internal
Overview
System properties can be provided with the -D command-line options, loaded from ~/.gradle/gradle.properties or from the project's gradle.properties. Explain precedence.
Properties
org.gradle.console
Sets console output coloring and verbosity.
org.gradle.daemon
org.gradle.debug
Starts Gradle in debug mode with the JVM listening on port 5005. Used together with --no-daemon. For more details see:
org.gradle.jvmargs
Attaching a Debugger to a Gradle Daemon
A Gradle daemon can be started in debug mode, so an IDE can attach and debug a build, by specifying JVM debug flags which ensure the JVM starts in suspend mode, as follows:
org.gradle.jvmargs="-agentlib:jdwp=transport=dt_socket,server=y,suspend=y,address=10001"
Note that once a Gradle daemon starts in debug mode, it remains in debug mode so the IDE can attach to it and debug successive builds without restarting the daemon. More details about Gradle debugging are available in: