I got rid of the "*" and it still didn't work...
I've tried two ways:
<exec executable="ls" failonerror="True">
<arg value="-l" />
</exec>
and
<exec executable="/usr/bin/ls" failonerror="True">
<arg value="-l" />
</exec>
I am using /urs/bin/ls because when I ask UNIX "whereis ls" it gave me
ls: /usr/bin/ls /usr/ucb/ls /usr/man/man1/ls.1 /usr/man/man1b/ls.1b
The error message is the same as before (in both cases):
[exec] Current OS is SunOS
[exec] /usr/bin/ls -l
BUILD FAILED
/home/rsu/prototype/exec.xml:19: exec returned: -1
at org.apache.tools.ant.taskdefs.ExecTask.runExecute(ExecTask.java,
Compiled Code)
at org.apache.tools.ant.taskdefs.ExecTask.runExec(ExecTask.java,
Compiled Code)
at org.apache.tools.ant.taskdefs.ExecTask.execute(ExecTask.java,
Compiled Code)
at org.apache.tools.ant.Task.perform(Task.java, Compiled Code)
at org.apache.tools.ant.Target.execute(Target.java, Compiled Code)
at org.apache.tools.ant.Target.performTasks(Target.java, Compiled Code)
at org.apache.tools.ant.Project.executeTarget(Project.java, Compiled
Code)
at org.apache.tools.ant.Project.executeTargets(Project.java, Compiled
Code)
at org.apache.tools.ant.Main.runBuild(Main.java, Compiled Code)
at org.apache.tools.ant.Main.start(Main.java, Compiled Code)
at org.apache.tools.ant.Main.main(Main.java, Compiled Code)
Is there something that I am missing here?
Thanks a lot!
Zhendi
Conor MacNeill wrote:
> > From: Diane Holt [mailto:[EMAIL PROTECTED]]
> >
> > Get rid of the "*" -- you don't need it, since 'ls -l' will list
> > everything anyway, and including an asterisk in the command line doesn't
> > work unless you exec 'sh' instead of 'ls'.
> >
>
> Just to expand a bit on Diane's explanation. On Unix systems, the shell is
> responsible for wildcard expansion, not the individual commands. when you
> pass "*" in Ant, the shell is not involved and the command receives the "*"
> char directly rather than a list of files.
>
> Conor
>
> --
> To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>