ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jeffrey E Care <ca...@us.ibm.com>
Subject Re: Batch file execution fails on Win XP with java.io.Exception error=2
Date Thu, 19 Jan 2006 13:24:54 GMT
Read the manual page for the <exec> task; it should give you a hint.

-- 
Jeffrey E. Care (carej@us.ibm.com)
WebSphere v7 Release Engineer
WebSphere Build Tooling Lead (Project Mantis)


Ramesh M <ramesh_mbabu@yahoo.com> wrote on 01/18/2006 07:34:11 AM:

> I have the folllowing fragment in an ant extension
> class.
> 
> String executable =3D "somebatchfile";
> commandline =3D new Commandline();
> commandline.setExecutable(executable)
> Command c =3D new Command(commandline);
> c.displayPrompt();
> c.setDir(testDomain);
> c.displayMake();
> c.run();
> 
> Where the "somebatchfile" comes from the build file.
> It does not 
> have any extension.
> On executing it on Windows XP I get the following
> error 
>  Cannot execute C:\somebatchfile: java.io.IOException:
> 
> CreateProcess: C:\somebatchfile.sh error=3D2 . The
> somebatchfile.cmd 
> is available on the folder, but it looks like it is
> looking for 
> a .sh file by default. 
> Any work around for this? The same works on Windows NT
> & Solaris
> (With a somebatchfile.sh in the folder).
> Thanks,
> Ramesh.
> 
> Regards,
> Ramesh 
> 
> 
> __________________________________________________
> Do You Yahoo!?
> Tired of spam?  Yahoo! Mail has the best spam protection around 
> http://mail.yahoo.com 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
> For additional commands, e-mail: user-help@ant.apache.org
> 

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message