ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Conelly, Luis (GNF, Contractor)" <Luis.Cone...@gnf.com>
Subject RE: Exec task in Ant 1.6.1
Date Wed, 14 Apr 2004 16:17:12 GMT
Maybe some of these messages can help you:

http://marc.theaimsgroup.com/?l=ant-user&m=104893196912661&w=2
http://marc.theaimsgroup.com/?l=ant-user&m=106860585724837&w=2
http://marc.theaimsgroup.com/?l=ant-user&m=106860836726736&w=2
http://ant.apache.org/manual/CoreTasks/apply.html

HTH
-Luis

-----Original Message-----
From: Rhino [mailto:rhino1@sympatico.ca]
Sent: Wednesday, April 14, 2004 11:08 AM
To: Ant Users List
Subject: Re: Exec task in Ant 1.6.1


The attempts I've made were unsuccessful; nothing at all was written to the
output file.

Do you have an example of running a .bat file from Ant? It doesn't need to
do DB2 stuff; a couple of 'dir' commands would do fine....

Rhino

----- Original Message ----- 
From: <Nick_Gianakas@sybari.com>
To: "Ant Users List" <user@ant.apache.org>
Sent: Wednesday, April 14, 2004 9:48 AM
Subject: Re: Exec task in Ant 1.6.1


> Hi Rhino,
>
> Have you tried putting all your tasks in a script file (.bat on Win32) and
> execute that script file from Ant?
>
> Regards,
> Nick G.
>
>
>
>
>
> "Rhino" <rhino1@sympatico.ca>
> 04/14/2004 09:36 AM
> Please respond to "Ant Users List"
>
>         To:     "ant-user" <user@ant.apache.org>
>         cc:
>         Subject:        Exec task in Ant 1.6.1
>
>
> Is it possible for an Exec task in Ant 1.6.1 to execute two or more
> commands in the same task?
>
> I am trying to take something that I do at the Windows XP command prompt
> and do it within an Ant script. Specifically, I do this:
> - launch a Windows XP command prompt via Start/All
> Programs/Accessories/Command Prompt
> - enter the following at the command prompt: db2cmd [This initializes the
> DB2 command line environment, making the next commands possible; they
> don't work at a normal command prompt.]
> - enter the following at the DB2 command prompt: db2 connect to sample
> - enter the following at the DB2 command prompt: db2 comment on specific
> procedure income_proc is 'xyz'
>
> I've tried pretty much everything you could imagine to imitate this in Ant
> but it never quite works.
>
> Unfortunately, although there are some DB2 commands that don't need a
> database connection before they will work, most DB2 commands *do* need a
> database connection, including the commands that I need to run. I think I
> need to get the connection and execute the command within the same task,
> although I could be wrong about that; perhaps I could get away with
> getting the connection in one task and then keep it open throughout the
> next task, which could contain the next command.
>
> Am I trying to do the impossible or have I just used the wrong technique?
>
> I'd really appreciate any suggestions that would help me get this working.
>
> Rhino
> ---
> rhino1 AT sympatico DOT ca
> "If you're getting something for nothing, you're not using your own credit
> card."
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
> For additional commands, e-mail: user-help@ant.apache.org
>


---------------------------------------------------------------------
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