https://issues.apache.org/bugzilla/show_bug.cgi?id=46737
Summary: Extend documentation of echo/java-when-forked tasks
Product: Ant
Version: 1.7.1
Platform: PC
OS/Version: Windows XP
Status: NEW
Severity: normal
Priority: P2
Component: Other
AssignedTo: [email protected]
ReportedBy: [email protected]
Please extend documentation of echo/java-when-forked tasks. The problem is with
special characters of the arg elements. Its not documented what should be
output of this simple test:
<project name="test" default="test">
<target name="test">
<property name="a" value=""src"" />
<echo>Variable is ${a}</echo>
<echo>Now lets see what exec do with quotes</echo>
<exec executable="echo">
<arg value="${a}" />
</exec>
<echo>It removes quotes - even when entered directly</echo>
<exec executable="echo">
<arg value=""src"" />
</exec>
</target>
</project>
On some systems it prints:
test:
[echo] Variable is "src"
[echo] Now lets see what exec do with quotes
[exec] src
[echo] It removes quotes - even when entered directly
[exec] src
on others
test:
[echo] Variable is "src"
[echo] Now lets see what exec do with quotes
[exec] "src"
[echo] It removes quotes - even when entered directly
[exec] "src"
It varies from different Java versions or platforms.
The very same for JAVA TASK when fork is set to "true"! A little bit dangerous.
--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.