experiences in software development
ActiveSupport implements Time#to_date. If you're not working on a Rails application, you could always borrow their implementation.
No kidding!Date, Time, and File objects in ruby could learn something from the Java core API. Oh well.
Using strftime isn't necessary. You just do:Date.parse(Time.now.to_s)(replace Time.now with your date object!)
Note: Only a member of this blog may post a comment.