diff --git a/README.md b/README.md
index 96188241c..9df51a2c6 100644
--- a/README.md
+++ b/README.md
@@ -38,7 +38,7 @@ Run **jadx** on itself:
### Usage
```
-jadx[-gui] [options] (.dex, .apk or .jar)
+jadx[-gui] [options] (.dex, .apk, .jar or .class)
options:
-d, --output-dir - output directory
-j, --threads-count - processing threads count
@@ -51,6 +51,16 @@ Example:
jadx -d out classes.dex
```
+### Troubleshooting
+##### Out of memory error:
+ - Reduce processing threads count (`-j` option)
+ - Increase maximum java heap size:
+ * command line (example for linux):
+ `JAVA_OPTS="-Xmx4G" jadx -j 1 some.apk`
+ * edit 'jadx' script (jadx.bat on Windows) and setup bigger heap size:
+ `DEFAULT_JVM_OPTS="-Xmx2500M"`
+
+---------------------------------------
*Licensed under the Apache 2.0 License*
*Copyright 2014 by Skylot*
diff --git a/jadx-cli/build.gradle b/jadx-cli/build.gradle
index 9687a01ef..4e616abaf 100644
--- a/jadx-cli/build.gradle
+++ b/jadx-cli/build.gradle
@@ -9,16 +9,6 @@ dependencies {
compile 'ch.qos.logback:logback-classic:1.1.2'
}
-startScripts {
- doLast {
- // increase default max heap size
- String var = 'DEFAULT_JVM_OPTS='
- String args = '-Xmx1300M'
- unixScript.text = unixScript.text.replace(var + '""', var + '"' + args + '"')
- windowsScript.text = windowsScript.text.replace(var, var + args)
- }
-}
-
applicationDistribution.with {
into('') {
from '../.'
diff --git a/jadx-gui/build.gradle b/jadx-gui/build.gradle
index 781e8aa37..3ae93258f 100644
--- a/jadx-gui/build.gradle
+++ b/jadx-gui/build.gradle
@@ -8,16 +8,6 @@ dependencies {
compile 'com.fifesoft:rsyntaxtextarea:2.5.0'
}
-startScripts {
- doLast {
- // increase default max heap size
- String var = 'DEFAULT_JVM_OPTS='
- String args = '-Xmx1300M'
- unixScript.text = unixScript.text.replace(var + '""', var + '"' + args + '"')
- windowsScript.text = windowsScript.text.replace(var, var + args)
- }
-}
-
applicationDistribution.with {
into('') {
from '../'