Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDarin Wright2003-02-12 20:25:21 +0000
committerDarin Wright2003-02-12 20:25:21 +0000
commit769dc44f777f67e527ae1be0e436003f5770931e (patch)
treecd56d065fa77ebb5ef79bd7083efe9085cf712de /org.eclipse.ui.externaltools/Program Tools Support
parent619714ff702b4fa8586b3f015ad7bdfe45a7ec15 (diff)
downloadeclipse.platform.debug-769dc44f777f67e527ae1be0e436003f5770931e.tar.gz
eclipse.platform.debug-769dc44f777f67e527ae1be0e436003f5770931e.tar.xz
eclipse.platform.debug-769dc44f777f67e527ae1be0e436003f5770931e.zip
bug 31369 - External Processes are not typed
Diffstat (limited to 'org.eclipse.ui.externaltools/Program Tools Support')
-rw-r--r--org.eclipse.ui.externaltools/Program Tools Support/org/eclipse/ui/externaltools/internal/program/launchConfigurations/ProgramLaunchDelegate.java15
1 files changed, 14 insertions, 1 deletions
diff --git a/org.eclipse.ui.externaltools/Program Tools Support/org/eclipse/ui/externaltools/internal/program/launchConfigurations/ProgramLaunchDelegate.java b/org.eclipse.ui.externaltools/Program Tools Support/org/eclipse/ui/externaltools/internal/program/launchConfigurations/ProgramLaunchDelegate.java
index 8c98dcc58..dc5ddee5d 100644
--- a/org.eclipse.ui.externaltools/Program Tools Support/org/eclipse/ui/externaltools/internal/program/launchConfigurations/ProgramLaunchDelegate.java
+++ b/org.eclipse.ui.externaltools/Program Tools Support/org/eclipse/ui/externaltools/internal/program/launchConfigurations/ProgramLaunchDelegate.java
@@ -10,6 +10,8 @@ Contributors:
**********************************************************************/
import java.io.File;
+import java.util.HashMap;
+import java.util.Map;
import org.eclipse.core.runtime.CoreException;
import org.eclipse.core.runtime.IPath;
@@ -92,8 +94,19 @@ public class ProgramLaunchDelegate implements ILaunchConfigurationDelegate {
Process p = DebugPlugin.exec(cmdLine, workingDir);
IProcess process = null;
+
+ // add process type to process attributes
+ Map processAttributes = new HashMap();
+ String programName = location.lastSegment();
+ String extension = location.getFileExtension();
+ if (extension != null) {
+ programName = programName.substring(0, programName.length() - (extension.length() + 1));
+ }
+ programName = programName.toLowerCase();
+ processAttributes.put(IProcess.ATTR_PROCESS_TYPE, programName);
+
if (p != null) {
- process = DebugPlugin.newProcess(launch, p, location.toOSString());
+ process = DebugPlugin.newProcess(launch, p, location.toOSString(), processAttributes);
}
process.setAttribute(IProcess.ATTR_CMDLINE, renderCommandLine(cmdLine));

Back to the top