> I have the following command line (see [1] for jsmin):
> jsmin < bigfile.js > smallfile.js "prefix file with this comment"
>
> To do this for an entire directory I created this task:
> <target name="jsmin">
> <apply executable="jsmin.exe" failonerror="true" dest="${dir.out}">
> <arg value=" < "/>
> <srcfile/>
> <arg value=" > "/>
> <targetfile/>
> <arg value="${comment}"/>
> <fileset dir="${dir.in}" includes="*.js"/>
> <mapper type="identity"/>
> </apply>
> </target>
>
> My suspicion is that the problem may be caused by the "<" and ">"
> characters in the command line. Could it be that they are ignored?
I've never used <redirector> yet either ;-)
The redirection "operators" you are using are not interpreted by the
jsmin.exe command, but by the shell that invokes the command; the
shell hooks bigfile.js to stdin and smallfile.js to stdout for the
executed command (jsmin.exe). Here, your <apply> calls directly
jsmin.exe, and bypasses the shell, so it doesn't work.
See http://ant.apache.org/faq.html#shell-redirect-2 for details.
Using <redirector> would probably make your script more portable, but
I can't help you there. --DD
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]