Juergen Kreileder wrote:

> These should be "to execute files".  If you want to use shell builtins
> or shell features like redirection you need a shell, e.g.:
> 
> Runtime.getRuntime().exec(new String[] {"/bin/sh",
>                                         "-c",
>                                         "ls / 2>&1 | tee ls.log"});

Oho, thats why my "ls > testfile" refused to work ... :-)
Another solution is to pack it in a shell script and execute this one

Urs


----------------------------------------------------------------------
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to