ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Fletcher, Michael \(Calgary\)" <MFlet...@petro-canada.ca>
Subject RE: Removing only the Children of a folder
Date Tue, 28 Mar 2006 14:55:33 GMT
I posted the email and it never appeared on the MARC website. I assumed
it was because I was not a member of the list so I signed up and posted
it again.

Sorry for the trouble.


I forgot one important detail in the email.  I do not have permission to
create the folder so I couldn't just run <mkdir ..>.  

Through trial and error I did figure it out.  For anyone searching the
lists this is the solution ...

-- CUT
<delete verbose="true" includeemptydirs="true">
   <fileset dir="\\pcaw2d1\wwwroot$\terminology" 
      defaultexcludes="false">

      <include name="*\**" />
        <!-- instead of <include name="**" /" -->

      <exclude name="Logs" />
      <exclude name="Logs" />

    </fileset>
</delete>
-- CUT AGAIN


-----Original Message-----
From: Jeffrey E Care [mailto:carej@us.ibm.com] 
Sent: March 28, 2006 4:11 AM
To: Ant Users List
Subject: Re: Removing only the Children of a folder



Just a helpful tip: the gurus on this list who hang out to help the
newbs usually find it really annoying when people post the same question
twice in one day. Please allow at least 48 hours before posting your
question again.
________________________________________________________________________
____________________ 
Jeffrey E. (Jeff) Care carej@us.ibm.com 
IBM WebSphere Application Server Development WAS Pyxis Lead Release
Engineer 
 



"Fletcher, Michael \(Calgary\)" <MFletche@petro-canada.ca> wrote on
03/27/2006 11:52:49 AM:

> Hello
> 
> I am trying to remove almost all of the files in a folder except for
the
> "Logs" folder and the folder itself.  Unfortunately if the folder
> doesn't contain any Logs then the whole folder is removed.
> 
> This is a snippet of my build.xml.
> 
> -- CUT
> <delete verbose="true" includeemptydirs="true">
>    <fileset dir="\\pcaw2d1\wwwroot$\terminology" 
>       defaultexcludes="false">
> 
>       <include name="**" />
>       <exclude name="Logs" />
> 
>       <!-- Do not delete the actual folder -->
>       <exclude name="." />
> 
>       
>    </fileset>
> </delete>
> -- CUT AGAIN
> 
> How should I do this?
> 
> Michael Fletcher
> Petro-Canada
>  
> --------------------------------------------------------
> 
> This email communication is intended as a private communication for 
> the sole use of the primary addressee and those individuals listed 
> for copies in the original message. The information contained in 
> this email is private and confidential and If you are not an 
> intended recipient you are hereby notified that copying, forwarding 
> or other dissemination or distribution of this communication by any 
> means is prohibited.  If you are not specifically authorized to 
> receive this email and if you believe that you received it in error 
> please notify the original sender immediately.  We honour similar 
> requests relating to the privacy of email communications.
>  
> Cette communication par courrier electronique est une communication 
> privee a l'usage exclusif du destinataire principal ainsi que des 
> personnes dont les noms figurent en copie.  Les renseignements 
> contenus dans ce courriel sont confidentiels et si vous n'etes pas 
> le destinataire prevu, vous etes avise, par les presentes que toute 
> reproduction, transfert ou autre forme de diffusion de cette 
> communication par quelque moyen que ce soit est interdite.  Si vous 
> n'etes pas specifiquement autorise a recevoir ce courriel ou si vous
> croyez l'avoir recu par erreur, veuillez en aviser l'expediteur 
> original immediatement.  Nous respectons les demandes similaires qui
> touchent la confidentialite des communications par courrier
electronique.
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
> For additional commands, e-mail: user-help@ant.apache.org
>
 
--------------------------------------------------------

This email communication is intended as a private communication for the sole use of the primary
addressee and those individuals listed for copies in the original message. The information
contained in this email is private and confidential and If you are not an intended recipient
you are hereby notified that copying, forwarding or other dissemination or distribution of
this communication by any means is prohibited.  If you are not specifically authorized to
receive this email and if you believe that you received it in error please notify the original
sender immediately.  We honour similar requests relating to the privacy of email communications.
 
Cette communication par courrier electronique est une communication privee a l'usage exclusif
du destinataire principal ainsi que des personnes dont les noms figurent en copie.  Les renseignements
contenus dans ce courriel sont confidentiels et si vous n'etes pas le destinataire prevu,
vous etes avise, par les presentes que toute reproduction, transfert ou autre forme de diffusion
de cette communication par quelque moyen que ce soit est interdite.  Si vous n'etes pas specifiquement
autorise a recevoir ce courriel ou si vous croyez l'avoir recu par erreur, veuillez en aviser
l'expediteur original immediatement.  Nous respectons les demandes similaires qui touchent
la confidentialite des communications par courrier electronique.

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message