How to redirect stderr in FreeBSD?
Neither of below worked
: ls 2> out.log
ls: 2: No such file or directory
: ls -al 2> error.log
ls: 2: No such file or directory
: (ls -al) 2> error.log
Badly placed ()'s.
How accomplish?
How to redirect stderr in FreeBSD?
Neither of below worked
: ls 2> out.log
ls: 2: No such file or directory
: ls -al 2> error.log
ls: 2: No such file or directory
: (ls -al) 2> error.log
Badly placed ()'s.
How accomplish?
csh
), rather than FreeBSD. See for example stderr redirection not working in csh – steeldriver Mar 31 '23 at 21:19ls
will do that unless you provide a filename on the command line that doesn't exist, for examplels -l notexist 2> error.log
. – Sotto Voce Mar 31 '23 at 21:34