This question already has an answer here:
- How to see if the directory exists? 3 answers
I have a file with a list of directories and I need to find out if they actually exist on the system. It's quite a large list so I'd like to figure out how to automate the check.
The file is formatted with each directory on a new line:
/usr/bin
/usr/sbin
/bin
/sbin
Any suggestions? Thanks!