Return-Path: Delivered-To: apmail-jakarta-ant-user-archive@jakarta.apache.org Received: (qmail 39911 invoked by uid 500); 20 Jun 2001 00:02:33 -0000 Mailing-List: contact ant-user-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: Reply-To: ant-user@jakarta.apache.org Delivered-To: mailing list ant-user@jakarta.apache.org Received: (qmail 39896 invoked from network); 20 Jun 2001 00:02:32 -0000 Reply-To: From: "Brett Knights" To: Subject: RE: Need help on making a dynamic build.xml Date: Tue, 19 Jun 2001 17:03:36 -0700 Message-ID: <000c01c0f91c$74a75de0$0201a8c0@knightsAPC.knightsofthenet.com> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook 8.5, Build 4.71.2173.0 In-Reply-To: <6DDA62170439D31185750000F80826AC0668452A@zmerd004.ca.nortel.com> Importance: Normal X-MimeOLE: Produced By Microsoft MimeOLE V4.72.2106.4 X-Spam-Rating: h31.sny.collab.net 1.6.2 0/1000/N This looks like something you could accomplish pretty easily with a script. Based on your directory structure your script would: create a copy task to send the files to be jarred to a working area create a jar task to do the work. (you actually might be able to get away with just scripting a jar task) HTH > -----Original Message----- > From: Jay Glanville [mailto:dickon@nortelnetworks.com] > Sent: Tuesday, June 19, 2001 7:25 AM > To: Ant-User (text) > Subject: Need help on making a dynamic build.xml > > > Perhaps calling this a "dynamic build.xml" is slightly > incorrect. But let > me tell you my situation before we worry over the semantics > of the title of > the problem. > > Basically, what I want to do is base what I deliver, and > where I deliver it > to, on the directory structure of my source code. > > For example, if my package/directory structure looks like this: > com.company.product_a.deliv_one > com.company.product_a.deliv_two > com.company.product_a.deliv_three > com.company.product_b.deliv_four > com.company.product_b.deliv_five > com.company.product_b.deliv_six > > after compiling all the source code, I want to jar everything > at the 4th > level (the deliv_ level) into a jar with the name of that > level, into a > directory based on the third level (the product_ level). > > Therefore, I want the resulting output of the above directory > structure to > look like this: > output/product_a/deliv_one.jar > .../deliv_two.jar > .../deliv_three.jar > output/product_b/deliv_four.jar > .../deliv_five.jar > .../deliv_six.jar > > If I could make a generic build.xml file based on this > philosophy, then > designers can create new products and deliverables without > having to modify > the build.xml file. > > So, does anybody have a suggestion on a way to do this? > > > -- > Jay Dickon Glanville > P068 - SiteManager Development, Nortel Networks > 613-765-1144 (ESN 395-1144) > MS: 045/55/A05 > E-Mail: dickon@nortelnetworks.com > >