That's right but you can't execute a batch file with ant ... you need cmd.exe or command exe to interpret it. If you start cmd wit the argument '/c' it should terminate after executing the command but it doesn't. Now i'm able to start tomcat but ant don't get the control back, the target in which i start tomcat never ends. Im just looking for a solution to start tomcat an run other tasks after that without killing tomcat after leaving the task.
Diane : thank for the link but the way, they describe it also hangs ant up any other hints ???? Peter ----- Original Message ----- From: "Mark C. Prins, CARIS bv." <[EMAIL PROTECTED]> To: "Ant Users List" <[EMAIL PROTECTED]> Sent: Wednesday, January 16, 2002 5:13 PM Subject: RE: Use bat-file with exec > the batch file _is_ the executable. > you could also try: > > <exec > executable="C:\Program Files\JavaSoft\JRE\1.3.1_01\bin\java.exe" > os="Windows NT, Windows 2000"> > <arg value="-jar"/> > <arg value="-Duser.dir=C:\Program Files\Apache Tomcat 4.0"/> > <arg value="C:\Program Files\Apache Tomcat 4.0\bin\bootstrap.jar"/> > <arg value="start"/> > </exec> > > > -----Original Message----- > > From: Peter Kesch [mailto:[EMAIL PROTECTED]] > > Sent: Wednesday, January 16, 2002 10:15 AM > > To: [EMAIL PROTECTED] > > Subject: Use bat-file with exec > > > > > > I try to stop and restart the tocat WebServer by Ant. > > But with > > <exec executable="cmd.exe"> > > <arg value="${tomcat}\bin\startup.bat" /> i also tried <arg > > value="c:\tomcat-3.2.3\bin\startup.bat" /> > > </exec> > > > > it doesn't work. > > > > i see only the message of cmd and than it hangs. > > With STRG+C i can break it but TOmcat isn't started. > > > > Has anyone a Hint > > > > Peter > > > > -- > To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> > For additional commands, e-mail: <mailto:[EMAIL PROTECTED]> > -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
