June 10th, 2009
In the hope that the Google Gods will help me next time I need this :-)
An easy way to generate a human-readable timestamp string, following the ISO 8601 standard, is:
Time.now.utc.iso8601.gsub(’-’, ’’).gsub(’:’, ’’)
Very handy if you need a timestamp in a file you’re writing.