AntumDeluge
May 1st, 2010, 02:05 AM
I'm trying to check if a directory exists under root, but if I don't have root permissions, it returns as false.
if [ -d "/root/Desktop" ]; then echo "hello world"; fi
How do I check for a root directory if I don't have permission? Or, how do I use my sudoer permissions to check for a directory?
if [ -d "/root/Desktop" ]; then echo "hello world"; fi
How do I check for a root directory if I don't have permission? Or, how do I use my sudoer permissions to check for a directory?