Skip to content

Commit e439f0d

Browse files
giuppeplayer-03
andauthored
Allow setting Gradle properties in project.xml (#1859)
* allow setting gradle jvmargs in project.xml * Make gradle.properties fully configurable from project.xml. --------- Co-authored-by: Joseph Cloutier <player3.14@gmail.com>
1 parent ab132da commit e439f0d

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

templates/android/template/gradle.properties

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,4 +29,6 @@ KEY_STORE=::KEY_STORE::
2929
KEY_STORE_PASSWORD=::KEY_STORE_PASSWORD::
3030
KEY_STORE_ALIAS=::KEY_STORE_ALIAS::
3131
KEY_STORE_ALIAS_PASSWORD=::KEY_STORE_ALIAS_PASSWORD::
32-
::end::
32+
::end::
33+
::foreach ANDROID_GRADLE_PROPERTIES::::if ((value != null) && (value != ""))::::key::=::value::
34+
::end::::end::

tools/platforms/AndroidPlatform.hx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -485,6 +485,7 @@ class AndroidPlatform extends PlatformTarget
485485
context.ANDROID_GRADLE_PLUGIN = project.config.getString("android.gradle-plugin", "8.7.3");
486486
context.ANDROID_USE_ANDROIDX = project.config.getString("android.useAndroidX", "true");
487487
context.ANDROID_ENABLE_JETIFIER = project.config.getString("android.enableJetifier", "false");
488+
context.ANDROID_GRADLE_PROPERTIES = project.config.getKeyValueArray("android.gradle-properties");
488489
context.ANDROID_DISPLAY_CUTOUT = project.config.getString("android.layoutInDisplayCutoutMode", "default");
489490

490491
context.ANDROID_APPLICATION = project.config.getKeyValueArray("android.application", {

0 commit comments

Comments
 (0)