file watcher job
I need a way to watch for a file and if the file exists run a script.
I think I have most of the pieces. I am hoping to use cron to run a statement similar to this. test -e $file if test -e $file = 0 then execute script fi this doesn't seem to work though. Can anybody tell me what I am doing wrong? Thanks |
I found an answer.
if [ -e $file ] ; then execute script fi This is the proper syntax and seems to work great. |
All times are GMT -5. The time now is 10:31 PM. |