Thread
:
avoid displaying errors while executing a script
View Single Post
#
4
(
permalink
)
10-30-2007, 04:33 AM
nixcraft
Never say die
User
Join Date: Jan 2005
Location: BIOS
My distro: Ubuntu
Posts: 1,035
Rep Power:
10
It should work...
Code:
rmdir x
rmdir: x: No such file or directory
So I did
Code:
rmdir x > /dev/null 2>&1
No error, you must not put any space between
2>&1
treat it as one word
__________________
Vivek
|
My personal blog
Linux Evangelist
Play hard stay cool
nixcraft
View Public Profile
Send a private message to nixcraft
Visit nixcraft's homepage!
Find all posts by nixcraft