The UNIX and Linux Forums  


Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
.
google unix.com




View Single Post in the UNIX and Linux Forums - Click on the Thread or Permalink to View Entire Thread -->
  #2 (permalink)  
Old 09-01-2008
Annihilannic Annihilannic is offline Forum Advisor  
  
 

Join Date: May 2008
Location: Sydney, Australia
Posts: 1,009
Why not ignore the seconds component completely and just do something like:

if grep -q ": $h:15.*SendToCM: run()" schedulerTrace.log then echo job did run else echo job did not run fi
Code:
if grep -q ": $h:15.*SendToCM: run()" schedulerTrace.log
then
      echo job did run
else
      echo job did not run
fi
        
-->
Code:
if grep -q ": $h:15.*SendToCM: run()" schedulerTrace.log
then
      echo job did run
else
      echo job did not run
fi

Last edited by Annihilannic; 09-01-2008 at 03:46 AM.. Reason: forgot the SendToCm part