Where can I find some examples on how to manipulate the time objects by days/hours/etc?
I would like to do this:
time.now_by_hour #=> "Tue Jun 15 23 MST 2010"
time.now_by_day #=> ""Tue Jun 15 MST 2010"
time.now_by_hour - 4.weeks - 3.days #=> "Sat May 15 MST 2010"
What is the recommended order of operations? The reason for this is I would like to run through lists of times and sort them by date to the hour, not to the minute and second.