Skip to main content



      Home
Home » Language IDEs » C / C++ IDE (CDT) » Running commands on Windows
Running commands on Windows [message #21832] Wed, 13 March 2002 09:10 Go to next message
Eclipse UserFriend
The command miner runs commands on Windows NT, 2000 and XP fine, but fails
on Windows 95, 98 and ME. This is because Windows NT, 2000 and XP use
"cmd /C" to start a command shell, but Windows 95, 98 and ME use "start
/B". The following code for the command miner fixes this problem:

theShell = "cmd /C ";

if ((theOS.indexOf("95")>=0) ||
(theOS.indexOf("98")>=0) ||
(theOS.indexOf("ME")>=0))
{
theShell = "start /B ";
}
_theProcess = Runtime.getRuntime().exec(theShell + _invocation,
getEnvironment(_subject), theDirectory);

Don Yantzi
Re: Running commands on Windows [message #21877 is a reply to message #21832] Wed, 13 March 2002 13:59 Go to previous message
Eclipse UserFriend
Thanks Don,

The code has been added and is available in CVS. The next published build
will incorporate this.

Dave

yantzi@ca.ibm.com wrote:

> The command miner runs commands on Windows NT, 2000 and XP fine, but fails
> on Windows 95, 98 and ME. This is because Windows NT, 2000 and XP use
> "cmd /C" to start a command shell, but Windows 95, 98 and ME use "start
> /B". The following code for the command miner fixes this problem:
>
> theShell = "cmd /C ";
>
> if ((theOS.indexOf("95")>=0) ||
> (theOS.indexOf("98")>=0) ||
> (theOS.indexOf("ME")>=0))
> {
> theShell = "start /B ";
> }
> _theProcess = Runtime.getRuntime().exec(theShell + _invocation,
> getEnvironment(_subject), theDirectory);
>
> Don Yantzi
Previous Topic:CORBA IDL to JAVA - Plugin is nearly finished (with full XML-Support)
Next Topic:CDT as top level project
Goto Forum:
  


Current Time: Thu Jul 10 01:22:22 EDT 2025

Powered by FUDForum. Page generated in 0.03575 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top