DirSet toString returns files
Closed this issue · 0 comments
twoseascharlie commented
Describe the bug
Using anything that would cause a DirSet toString returns files instead of directories.
Steps To Reproduce
Example build.xml:
<?xml version="1.0" encoding="UTF-8" ?>
<project name="tmp.testing" basedir="." default="tmp.test.dirs">
<property environment="env" />
<property name="source.root" value="${phing.dir}" />
<echo msg="source.root: ${source.root}" />
<target name="tmp.test.dirs">
<dirset id="dist.contents" dir="${source.root}" includes="src/**">
</dirset>
<property name="prop.dist.contents" refid="dist.contents"/>
<echo msg="prop.dist.contents: ${prop.dist.contents}" />
</target>
<target name="tmp.test.files">
<fileset id="dist.contents" dir="${source.root}" includes="src/**">
</fileset>
<property name="prop.dist.contents" refid="dist.contents"/>
<echo msg="prop.dist.contents: ${prop.dist.contents}" />
</target>
</project>
Check files:
$ phing tmp.test.files
Buildfile: /var/www/html/checkHookPlugin/build.xml
[echo] source.root: /var/www/html/checkHookPlugin
tmp.testing > tmp.test.files:
[echo] prop.dist.contents: src/plugins/check-hooks/autoload/MainAutoload.php;src/plugins/check-hooks/main/activate/ActivatePlugin.php;src/plugins/check-hooks/plugin-main.php
BUILD FINISHED
Total time: 0.1959 seconds
Check directories:
$ phing -f buildtemp.xml tmp.test.dirs
Buildfile: /var/www/html/checkHookPlugin/build.xml
[echo] source.root: /var/www/html/checkHookPlugin
tmp.testing > tmp.test.dirs:
[echo] prop.dist.contents: src/plugins/check-hooks/autoload/MainAutoload.php;src/plugins/check-hooks/main/activate/ActivatePlugin.php;src/plugins/check-hooks/plugin-main.php
BUILD FINISHED
Total time: 0.1916 seconds
Expected behavior
Only directories should be listed with DirSet
Screenshots / terminal output
See above
Additional context
This is using latest of phing/main.