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 -->
  #4 (permalink)  
Old 03-16-2008
Franklin52 Franklin52 is online now Forum Staff  
Moderator
  
 

Join Date: Feb 2007
Posts: 4,333
It should be something like:


Code:
date --date "2008-03-15 11:40 5 min ago" +%F==%I:%M

But what is the reason for using this format "+%F==%I:%M"?
You can get the epoch time of 5 minutes ago with:


Code:
date --date "2008-03-15 11:40 5 min ago" +%s

Regards