Aw: Re: macrodef with parameters to pass to java task

2017-05-29 Thread Al Le
Yes, it works! Thank you! > Gesendet: Montag, 29. Mai 2017 um 12:16 Uhr > Von: "Stefan Bodewig" > An: user@ant.apache.org > Betreff: Re: macrodef with parameters to pass to java task > > On 2017-05-29, Al Le wrote: > > > in my ant script I'd like to

Re: macrodef with parameters to pass to java task

2017-05-29 Thread Stefan Bodewig
On 2017-05-29, Al Le wrote: > in my ant script I'd like to define a macro (via macrodef) which would call > the 'java' task as a part of its body/implementation. > In the java task call in the macro, I want to just specify the main class > name and the classpath. The parameters (which are usual

Aw: Re: MacroDef: Setting attribute via API should convert to lowercase

2016-04-17 Thread Al Le
> Thanks, should be fixed in git, will be fixed in 1.9.8 and 1.10.0. That's not fair! I've needed so long to identify the problem and create a bug report, and you fix it so quickly! :-) - To unsubscribe, e-mail: user-unsubscr...

Re: MacroDef: Setting attribute via API should convert to lowercase

2016-04-16 Thread Stefan Bodewig
On 2016-04-17, Al Le wrote: >> Please open a bug ticket. > Created the bug report 59339. Thanks, should be fixed in git, will be fixed in 1.9.8 and 1.10.0. Stefan - To unsubscribe, e-mail: user-unsubscr...@ant.apache.org For

Re: MacroDef: Setting attribute via API should convert to lowercase

2016-04-16 Thread Al Le
My guess is that you are the first person who's trying what you do and you've simply hit a bug. [...] Please open a bug ticket. Created the bug report 59339. - To unsubscribe, e-mail: user-unsubscr...@ant.apache.org For addit

Re: MacroDef: Setting attribute via API should convert to lowercase

2016-04-16 Thread Stefan Bodewig
On 2016-04-12, Al Le wrote: > in my ant script, I define a task "MyTask" via "macrodef". The task > has a mandatory attribute "nodeName" (not the camelCase name). > Then I call the task from a javascript snippet: > var myTask = project.createTask('myTask'); > myTask.setDynamicAttribute("nodeName

Re: Macrodef and If

2011-11-11 Thread Stefan Bodewig
On 2011-11-09, Steve Amerige wrote: > Thanks for your reply. This won't work because the macrodef won't > have any knowledge of what to do as per my need. I have to trust you on that. > I think, therefore, my solution of having 2 macrodef elements is as > close as I can get: > > ... > ... >

Re: Macrodef and If

2011-11-09 Thread Steve Amerige
Hi Stefan, Thanks for your reply. This won't work because the macrodef won't have any knowledge of what to do as per my need. I think, therefore, my solution of having 2 macrodef elements is as close as I can get: ... ... So, then the question shifts a bit: in a macrodef, assuming that an

Re: Macrodef and If

2011-11-08 Thread Stefan Bodewig
On 2011-11-08, Steve Amerige wrote: > I'd like to do something like: > > > > ... > > > >... > > Within the macrodef, there would be places it would return true and > other places it returns false. I want the solution to be wholly in > Ant (no Java, Groo

Re: Macrodef and If

2011-11-08 Thread Steve Amerige
Hi, Thanks for the feedback. Actually, the use of Ant-Contrib is okay. But, please note that it isn't just a property that I'd want to set. It's really the ability to look at the "return" values of a macrodef and use that result with an task. I do realize that a workaround exists in this fo

RE: Macrodef and If

2011-11-08 Thread Murray, Mike
Assuming no use of AntContrib, you can pass the name of a property to the Macrodef, which it would set. This property could then be used in an Ant condition. I'd give in and use AntContrib though, since it gives you an task. -Original Message- From: Steve Amerige [mailto:steve.amer.

Re: Macrodef attribute expansion question...

2009-07-08 Thread Scot P. Floess
OK, I found my problem... Apparently as I was refactoring, I moved my statement to the bottom of my XML file containing macrodefs... The aforementioned macrodef's had references to the properties contained in the file :( Anyway, I moved the up above my macrodef's and it worked... Funn

Re: Macrodef attribute expansion question...

2009-07-08 Thread Scot P. Floess
Hey thanks! OK, now I feel like a complete idiot! So, in my code I am doing this exactly - or so I think ;) Like a "bull in a china shop" I went ahead and did this sample app... Now looking at your example, and going back to my code I see where I have an error-msg attribute that default

Re: Macrodef attribute expansion question...

2009-07-08 Thread Stefan Bodewig
On 2009-07-08, Scot P. Floess wrote: > I have a question about attribute expansion for macrodefs... > Consider the following: > > > > > > > > >"${myMessage1}"/> >

RE: Re: macrodef and classpath

2009-02-06 Thread cknell
: Ant Users List Subject: Re: macrodef and classpath Hi, Thanks, but no. I have my macrodefs stored in one file, and I import it in the 'real' build file like so: I want to pass in my 'real' build properties to the macrodefs without defining values in the macrodef fi

Re: macrodef and classpath

2009-02-06 Thread Mark Waschkowski
Hi, Thanks, but no. I have my macrodefs stored in one file, and I import it in the 'real' build file like so: I want to pass in my 'real' build properties to the macrodefs without defining values in the macrodef file. This works using elements, but not with attributes - am I missing something?

RE: macrodef and classpath

2009-02-06 Thread cknell
I set up properties in the "init" target and use references to them in the macrodefs. Here's an example I then refer to the property in the macrodef ex.

Re: macrodef and uri

2006-06-09 Thread Scot P. Floess
Peter: Thanks for the reply... I had found the answer shortly after I posted...For some reason it never "clicked" about adding the namespace at the level...I sorta felt silly once I realized that ;) Regardless, I appreciate you responding...thanks again :) Scot Peter Reilly wrote: In par

Re: macrodef and uri

2006-06-09 Thread Peter Reilly
In particular a uri is not a namespace prefix. One needs to map a prefix to a uri using the xmlns attribute. Hello world Peter On 6/8/06, Scot P. Floess <[EMAIL PROTECTED]> wrote: OK, someone feel free to kick me and call me a newbie! I found my problem...

Re: macrodef and uri

2006-06-08 Thread Scot P. Floess
OK, someone feel free to kick me and call me a newbie! I found my problem... I didn't define the namespace in the Regardless...disregard! Scot P. Floess wrote: I am trying to find some examples using a uri on macrodef... My assumption was, if I used a uri, I could use that to prefix using t

RE: macrodef

2006-01-17 Thread Ivan \"Rambius\" Ivanov
Hello Paulo, it depends on the macrodef. I had a situation where I wrapped and in one macrodef since that piece of code was repeated several times. Later, it turned out that some invoka tions of that macrodef required different 's. So I added a macrodef element that allows passing different pro

RE: macrodef

2006-01-17 Thread Paulo Jorge Guedes
> -Original Message- > From: Alexey N. Solofnenko [mailto:[EMAIL PROTECTED] > Sent: terça-feira, 17 de Janeiro de 2006 19:21 > To: Ant Users List > Subject: Re: macrodef > > Well, you can do it via internal ANT API, but it would be a too complex > solution for

Re: macrodef

2006-01-17 Thread Alexey N. Solofnenko
Well, you can do it via internal ANT API, but it would be a too complex solution for the task. - Alexey. Paulo Jorge Guedes wrote: -Original Message- From: Alexey N. Solofnenko [mailto:[EMAIL PROTECTED] Sent: terça-feira, 17 de Janeiro de 2006 18:23 To: Ant Users List Subject: Re

RE: macrodef

2006-01-17 Thread Paulo Jorge Guedes
> -Original Message- > From: Alexey N. Solofnenko [mailto:[EMAIL PROTECTED] > Sent: terça-feira, 17 de Janeiro de 2006 18:23 > To: Ant Users List > Subject: Re: macrodef > > You can overwrite the macrodef in your build file or you can copy the > file first, then i

Re: macrodef

2006-01-17 Thread Alexey N. Solofnenko
You can overwrite the macrodef in your build file or you can copy the file first, then insert necessary elements into that copy. - Alexey. Paulo Jorge Guedes wrote: Hi, I have a target (-init-macrodef-junit ) that initializes "junit" target using the "macrodef" element. It doesn't declare the

Re: Macrodef Problem Urgent

2005-11-09 Thread Dominique Devienne
> i'm using ant 1.6.0 This should be working then. You may have a mix of Ant versions then. Are you running from the command line or an IDE? Windows or *nix? I'd check you ant setup. Also, try a minimal build file with an hello word macro that reproduces the problem, and send this whole build. Ju

Re: Macrodef Problem Urgent

2005-11-09 Thread Andrei
i'm using ant 1.6.0 From: "Steve Loughran" <[EMAIL PROTECTED]> To: "Ant Users List" Sent: Wednesday, November 09, 2005 2:57 PM Subject: Re: Macrodef Problem Urgent Andrei wrote: Hi guys. I have a problem with macrodef usage. I decl

Re: Macrodef Problem Urgent

2005-11-09 Thread Steve Loughran
Andrei wrote: Hi guys. I have a problem with macrodef usage. I declared a macrodef to start jBoss and here is the target who uses

RE: macrodef: setting options dynamically

2005-06-15 Thread hind.lwahhabi
hi jan; i already saw the manual but my goal is a little bit more complex; i want to do the following: attribute1 and attribute2 belong to macrodef SomeMacro. if attribute1=x then attribute2="blablabla @{attribute1" else attribute2="other blabla" Thanks for any help. -Original Message---

RE: macrodef+fileset

2005-06-14 Thread Bill Rich
The attached macro snippet does something like what you want. It takes filetypelist as a parameter. filetypelist is a semi-colon separated list of items from a control file. HTH Bill -Original Message- From: [EMAIL PROTECTED] [mailto:[E

Re: Macrodef in import file having same behaviour as targets?

2005-01-04 Thread galenboyerdev
Yves Leung-Tack <[EMAIL PROTECTED]> writes: > Hi, > > Is it possible for ant to get a filename , parsing it > and get a substring of that filename for using it ?? > > What I want to do exactly in build.xml is: > if a file with *QAE.tar.gz exists then > parse the that filename

Re: Macrodef in import file having same behaviour as targets?

2005-01-04 Thread Yves Leung-Tack
Hi, Is it possible for ant to get a filename , parsing it and get a substring of that filename for using it ?? What I want to do exactly in build.xml is: if a file with *QAE.tar.gz exists then parse the that filename to get the substring from index 4 to 9 use that substrin

Re: Macrodef in import file having same behaviour as targets?

2005-01-04 Thread galenboyerdev
Peter Reilly <[EMAIL PROTECTED]> writes: > [EMAIL PROTECTED] wrote: > > >Martin Cooper <[EMAIL PROTECTED]> writes: > > > >> You may be running into a bug that has been fixed but is not yet in a > >> release. Does anybody know if this is true? > No, it is not true. Thank you for the answe

Re: Macrodef in import file having same behaviour as targets?

2005-01-04 Thread Peter Reilly
[EMAIL PROTECTED] wrote: Martin Cooper <[EMAIL PROTECTED]> writes: > You may be running into a bug that has been fixed but is not yet in a > release. Does anybody know if this is true? No, it is not true. I'm guessing there is still some work to get ant working the way I was hoping. Yes

Re: Macrodef in import file having same behaviour as targets?

2004-12-30 Thread galenboyerdev
Martin Cooper <[EMAIL PROTECTED]> writes: > You may be running into a bug that has been fixed but is not yet in a > release. Does anybody know if this is true? I'm guessing there is still some work to get ant working the way I was hoping. But, I would at least like to override the macr

Re: Macrodef in import file having same behaviour as targets?

2004-12-30 Thread galenboyerdev
Martin Cooper <[EMAIL PROTECTED]> writes: > You may be running into a bug that has been fixed but is not yet in a > release. Try putting your macrodefs inside targets, and using the > appropriate depends to ensure those targets are invoked first. I'm okay with the target idea, just wondering if m

Re: Macrodef in import file having same behaviour as targets?

2004-12-30 Thread Martin Cooper
You may be running into a bug that has been fixed but is not yet in a release. Try putting your macrodefs inside targets, and using the appropriate depends to ensure those targets are invoked first. -- Martin Cooper On Thu, 30 Dec 2004 [EMAIL PROTECTED] wrote: HERE IS MY EXAMPLE IMPORT FILE:

Re: macrodef / subant inherit problem

2004-05-24 Thread Peter Reilly
A cut-down version of the build/import files that shows the problem would be helpfull. I have run a small test: top dir: im.xml top.xml build.properties p=top sub dir: - sub.xml SUB: basedir="${basedir}" p is ${p} build.pr

Re: Macrodef @{x}

2003-12-03 Thread Jacob Kjome
This is offtopic from the macrodef change, but the xml-apis.jar seems to have mysteriously reverted to a much older one. Even recently it had been the one from Xerces-2.6.0. xercesImpl.jar *is* from 2.6.0, but xml-apis.jar is from back in 2002. It should be 122k and is only 106k right now.

Re: macrodef and depends

2003-11-19 Thread Stefan Bodewig
On Tue, 18 Nov 2003, Corey Jewett <[EMAIL PROTECTED]> wrote: > That said, I haven't found a way to have a macrodef _transparently_ > depend on another target. Well, macrodef defines a task - and thus has no way to specify dependencies, just like "normal" tasks don't have either. I find it quite

RE: MacroDef: use attribute inside another attributes default cla use

2003-10-21 Thread Dominique Devienne
> From: peter reilly [mailto:[EMAIL PROTECTED] > > This won't work as the default attribute gets processed by ant before > macrodef sees it. > for example: > > > > > > bar is ${bar} > > > > > generates > foo: > bar is global foo And this time I think I'm right Peter when