IDEA-108602 Gradle: Integrate 'debug task' to the execution system

Trimming vm options before distributing them to the gradle api. It seems that the later is rather fragile in a way that it fails if the options starts with white space
This commit is contained in:
Denis.Zhdanov
2013-06-10 09:19:10 +04:00
parent a47480e684
commit eea6ea5716
@@ -51,8 +51,8 @@ public class GradleTaskManager implements ExternalSystemTaskManager<GradleExecut
@Override
public Void fun(ProjectConnection connection) {
BuildLauncher launcher = myHelper.getBuildLauncher(id, connection, settings, listener);
if (!StringUtil.isEmpty(vmOptions)) {
launcher.setJvmArguments(vmOptions);
if (vmOptions != null) {
launcher.setJvmArguments(vmOptions.trim());
}
launcher.forTasks(ArrayUtil.toStringArray(taskNames));
launcher.run();