In general for any system the only reasons to execute a command in the
same shell are:
1) for some reason you need to set environment variables that need to be
available to the "parent" shell
2) there is some problem with getting all of the "parent's" variables
-- the exec system call used doesnot pass the environment variables
-- the variables are not environment variables
-- the shell being exec'ed is not the one you want
For ant there are fairly simple mechanisms to get around each of these
issues however, Robert I don't think these are your problems.
--------------------------------------------------------------------------------------
Robert Priest <Robert.Priest@bentley.com>
11/18/2003 12:52 PM
Please respond to "Ant Users List"
To: "'Ant Users List'" <user@ant.apache.org>
cc:
Subject: RE: Exec creates a new Shell?
Thanks for the response Chris.
So do you (or anyone else) have any suggestions for being able to run a
command in ant in the CURRENT shell that ant is running in?
-----Original Message-----
From: Christopher Schultz [mailto:christopher.d.schultz@comcast.net]
Sent: Monday, November 17, 2003 10:45 PM
To: Ant Users List
Subject: Re: Exec creates a new Shell?
Robert,
> Does the Exec command create a new cmd shell on Winnt systems?
Yep. It creates a new shell on UNIX systems, too. Otherwise, it would
not be able to run programs and wait for them to finish...
---------------------------------------------
Brian.Colfer@kp.org
Phones:
Office: (925) 979-7498
Mobile: (415) 505-5480
Personal Email: BrianColfer@covad.net
-----------------------------------------------
|