Is it possible to override `jvmargs` , which decla...
# gradle
t
Is it possible to override
jvmargs
, which declared in
gradle.properties
:
Copy code
org.gradle.jvmargs=-Xmx2g
to have less memory on CI only?
v
If you set it in
~/.gradle/gradle.properties
or via commandline argument it should overwrite the
gradle.properties
value in the root project directory.
👍 1
t
Like this?
Copy code
./gradlew build -Dorg.gradle.jvmargs=-Xmx8g
v
No, that is setting a system property, not a gradle property. Gradle property is with
-P
. Except if the same is considered as system property too, for some this is the case, not sure whether for that one, just try it. 🙂
🙏 1
t
as alternative solution - you could provide different location for
GRADLE_USER_HOME
which will contain
gradle.properties
with jvmargs override
🧌 2