I can't tell from your original post everything you intend to do with this information once you get it, but you may want to have a look at the <tokens> resource collection.
HTH, Matt --- On Tue, 3/31/09, Dylan Farre <[email protected]> wrote: > From: Dylan Farre <[email protected]> > Subject: Extracting information out of a file > To: [email protected] > Date: Tuesday, March 31, 2009, 7:50 AM > I am looking for a generic way (Ant > task) to extract information out of a > file. For example I have a sql script that calls other sql > scripts. I want > to be able to extract the list of these sub scripts. It > would be great if > the task would put them in an AntXtras strings type > contruct, or something > equivalent (AntContrib maybe?). Ideally, this task would > allow me to use > regex pattern matching for the start and end tokens of the > data I want to > extract. > > For example sql_main.sql: > > ... > connect &&user/&&pass@&&db start > &&db.sub_1.sql > .... > > I would want to dynamically get the c_d_trig.sql put into a > AntXtras strings > or equivalent, by specifying the start token as > ".*&&db." or even just "." > and the end token as "
" > > Any help will be appreciated. > P.S. If no one can help, I'll try the AntXtras forum. Is > there a separate > forum for Ant-Contrib? > Thanks. > --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
