You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by no...@apache.org on 2020/04/17 13:38:06 UTC

[cordova-docs] branch master updated: docs: JVM args (#1078)

This is an automated email from the ASF dual-hosted git repository.

normanbreau pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/cordova-docs.git


The following commit(s) were added to refs/heads/master by this push:
     new 9bc7b4f  docs: JVM args (#1078)
9bc7b4f is described below

commit 9bc7b4f92d18c37de176b94e739877329419b710
Author: Norman Breau <no...@normanbreau.com>
AuthorDate: Fri Apr 17 10:37:57 2020 -0300

    docs: JVM args (#1078)
---
 www/docs/en/dev/guide/platforms/android/index.md | 18 ++++++++++++++++++
 1 file changed, 18 insertions(+)

diff --git a/www/docs/en/dev/guide/platforms/android/index.md b/www/docs/en/dev/guide/platforms/android/index.md
index 41e4496..a70f619 100644
--- a/www/docs/en/dev/guide/platforms/android/index.md
+++ b/www/docs/en/dev/guide/platforms/android/index.md
@@ -284,6 +284,24 @@ Note that plugins can also include `build-extras.gradle` files via:
 <framework src="some.gradle" custom="true" type="gradleReference" />
 ```
 
+#### Configuring Gradle JVM Args
+
+To change the Gradle JVM args, the `--jvmargs` flag can be used with both cordova build and run commands. This is mostly useful for controlling how much memory gradle is allowed to use during the build process. It is recommended to allow at least 2048 MB.
+
+By default, JVM args has a value of `-Xmx2048m`. To increase the max allowed memory, use the `-Xmx` JVM arg. Example given below:
+
+```
+cordova build android -- --jvmargs='-Xmx4g'
+```
+
+The following units are supported:
+
+| unit      | value     | example
+|-----------|:---------:|---------
+| kilobyte  |k          |`-Xmx2097152k`
+| megabyte  |m          |`-Xmx2048m`
+| gigabyte  |g          |`-Xmx2g`
+
 ### Setting the Version Code
 
 To change the [version code](https://developer.android.com/studio/publish/versioning.html)


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org