DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT <http://nagoya.apache.org/bugzilla/show_bug.cgi?id=4633>. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE.
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=4633 Global filtering via "filtering" attribute does not work with copy task Summary: Global filtering via "filtering" attribute does not work with copy task Product: Ant Version: 1.4.1 Platform: Sun OS/Version: Solaris Status: NEW Severity: Major Priority: Other Component: Core tasks AssignedTo: [EMAIL PROTECTED] ReportedBy: [EMAIL PROTECTED] Global filtering does not work with copy task at all following instructions in the manual. To reproduce, consider the following example: 1. Make a build.xml that contains the following: <project name="test" default="test"> <property file="build.properties" /> <filterset id="filterconf" begintoken="@" endtoken="@"> <filtersfile file="./test.properties"/> </filterset> <target name="test"> <copy file="./test.file" tofile="./output" filtering="true"> </copy> </target> </project> 2. Create a file called test.properties that contains the following: TEST_TOKEN=nobug 3. Create a file to copy called test.file that contains the folllowing: Is there a bug? @TEST_TOKEN@ 4. Perform the following command: ant -verbose 5. Output shows that the filter file is loaded initially, but there is no confirmation that replacement took place on test.file. Open the file called output and you will still see: @TEST_TOKEN@ ---------- no replacement was made! I have confirmed a workaround although it seriously will bloat build files: Write your copy tasks like this: <copy file="./test.file" tofile="./output"> <filterset begintoken="@" endtoken="@"> <filtersfile file="./test.properties" /> </filterset> </copy> In other words, nested filtersets still work, but the filtering attribute of the copy task does not. -Peter -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
