Hi,

Long Wind wrote on Sun, Aug 17, 2014 at 07:27:09AM +0800:

> how to direct ouput by a command to file (so I can report error here)
> 
> pkg_add nedit > t1
> 
> doesn't work

That only catches standard output, not standard error.

Both of the following should work:

 $ pkg_add nedit > t1 2>&1       # to the file only
 $ pkg_add nedit 2>&1 | tee t1   # to the file and to the screen

Let me take a blind guess regarding your problem:

  http://www.openbsd.org/faq/faq15.html#NoFun

Yours,
  Ingo

Reply via email to