Date Time Stamp

I'm trying to write a script that checks the DTS of a file the compares it to the current time. If greater that 60 mins has gone by and the file has not been written to alert.

So far I have the time pulled from the file but I dont know how to compare the times against a 60 min difference.

#!/bin/ksh
# Check to see if the Control File has been updated hourly

stime=`date +%H:%M`
CHECK()
{
ls -al | grep filename |awk '{ print $8 }' > $ntime
}

Did you try to use find command with different options like -

Time in seconds since a file was last modified...

perl -e '@q=stat($ARGV[0]); print time-$q[9]' file1