Last active
June 12, 2019 19:35
-
-
Save doyle/896744982904354ac2a76e2fb2d6b718 to your computer and use it in GitHub Desktop.
Shows common ways of formatting dates as strings
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# 2019-10-14 14:32:55 -0400 | |
Time.now.strftime('%Y-%m-%d %H:%M:%S %z') | |
# 2019-10-14 14:35:18.969 -0400 | |
Time.now.strftime('%Y-%m-%d %H:%M:%S.%L %z') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment