How do I increase Groovy's JVM Heap Size?

jonalv picture jonalv · Mar 28, 2011 · Viewed 15.3k times · Source

Some sources on the web claims that I should be able to give the -Xmx param to groovy but that just gives me java.io.FileNotFoundException when it can't find the -Xmx file. Other sources tell me to set some variable named JAVA_OPTS but how do I do that? And how do I know if it worked?

Answer

Heiko Rupp picture Heiko Rupp · Mar 28, 2011
$ export JAVA_OPTS="$JAVA_OPTS -Xmx64M"
$ groovy