How can I check for a not empty directory and do something if a file lands in it.
Example:
I would like to have e-smith check /user/Maildir/new for any new email files that appear and run a cron job to send a beep to the consol.
I am just looking for the routine or command to use to see if a directory has any files in it.
Thanks.