Created
November 24, 2011 19:14
-
-
Save ludofleury/1392040 to your computer and use it in GitHub Desktop.
Ant build.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<target name="lint"> | |
<apply executable="php" failonerror="true"> | |
<arg value="-l" /> | |
<fileset dir="${basedir}"> | |
<include name="**/*.php" /> | |
<exclude name="**/vendor*" /> | |
<modified /> | |
</fileset> | |
<fileset dir="${basedir}/Tests"> | |
<include name="**/*.php" /> | |
<modified /> | |
</fileset> | |
</apply> | |
</target> |
To help in your test, replace the php command by ls (lot faster)
Sorry replace php command by ls ? any example ? I don't get it but it seems a cool feature
C'est une astuce si tu veux voir quels sont les fichiers inclus dans le filset :
<target name="lint">
<apply executable="ls" failonerror="true">
<arg value="-l" />
<fileset dir="${basedir}">
<include name="**/*.php" />
<exclude name="**/vendor/**" />
<modified />
</fileset>
<fileset dir="${basedir}/Tests">
<include name="**/*.php" />
<modified />
</fileset>
</apply>
</target>
Et je sais pas si tu sais, mais pour appeller uniquement lint c'est :
ant lint
oooow really smart, didn't think to do that and thanks for the cmd, I'm switching from phing to ant ;)
Yet I can't find any pattern that exclude the vendor dir it's still be crawled
Juste looked at my build files. It's **/vendor/**
(It's confusing, each tool has its own syntax)
Just figured out in the same time... gosh as you said "confusing"... Anyway thank you very much for your help, you won beer ;)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
You should try vendor/*