sreangsu acharyya forced the electrons to say:
>   is there anyway by which one can compare 2 date strings as returned by
> "date" in bash.

You can ask date to print output in a comparable format; like

if [ $( date '+%Y%m%d%H%M%S' ) -gt 20001226000000 ]; then
   echo 'Oops! Forgot all about Christmas presents'
fi

See date(1) for details.

Binand


----------------------------------------------
LIH is all for free speech.  But it was created
for a purpose.  Violations of the rules of
this list will result in stern action.

Reply via email to