startScripts { // The option -XX:+UseG1GC is only relevant for Java 8. Starting with Java 9 G1GC is already the default GC defaultJvmOpts = ['-Xms128M', '-Xmx4g', '-Dawt.useSystemAAFontSettings=lcd', '-Dswing.aatext=true', '-XX:+UseG1GC'] defaultJvmOpts = ['-Xmx8g', '-Xmx12g', '-Dawt.useSystemAAFontSettings=lcd', '-Dswing.aatext=true', '-XX:+UseG1GC'] doLast { def str = windowsScript.text str = str.replaceAll('java.exe', 'javaw.exe')