TheOldWiseKing wrote:
S A

I found a good solution, here is the command:

ls > file1.txt | cat file1.txt > file2.txt

Not so wise OldWiseKing. :)

I don't know what the pipe is for, but I don't think that will work. file2.txt will likely end up empty.

Maybe you meant:

ls > file1.txt; cat file1.txt > file2.txt

What you really want as someone else mentioned is a tee as in:

ls |tee file1.txt > file2.txt

It's a lot cleaner and probably more efficient.

--
Until later, Geoffrey

Those who would give up essential Liberty, to purchase a little
temporary Safety, deserve neither Liberty nor Safety.
 - Benjamin Franklin
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to