How to exclude directories from phing copy task

I installed Phing 2.4.7.1 on Windows 7 and use the cygwin bash shell

I created a Phing task to copy files to a local directory and compress files, but I try to exclude certain directories without success. copy the entire directory

The task is as follows:

<copy todir="${builddir}" includeemptydirs="true" >
    <fileset dir="." defaultexcludes="true">                
         <exclude name="cache/*" />
         <exclude name="build.*" />
         <exclude name="log/*" />
         <exclude name=".git" />
         <exclude name="/data/*" />
         <exclude name="/nbproject" />
         <exclude name="*~" />
    </fileset>
</copy>
+5
source share
2 answers

Use two *for subfiles:

<exclude name="cache/**"/>
+6
source

Well, I don't know if this is not just a tag for reading people, but something like this worked for me:

<fileset dir=".">                           
    <patternset>
        <include name="**/*.*" />
        <exclude name="dist/**" />
    </patternset>
</fileset>
+2
source

All Articles