Skip to content

Instantly share code, notes, and snippets.

@ejfinneran
Created February 3, 2012 04:38
Show Gist options
  • Save ejfinneran/1727966 to your computer and use it in GitHub Desktop.
Save ejfinneran/1727966 to your computer and use it in GitHub Desktop.
Date weirdness
Loading development environment (Rails 3.1.0)
ruby-1.9.2-p290 :001 > Date.today
=> Thu, 02 Feb 2012
ruby-1.9.2-p290 :002 > Date.tomorrow
=> Sat, 04 Feb 2012
ruby-1.9.2-p290 :003 > Time.zone = "America/Chicago"
=> "America/Chicago"
ruby-1.9.2-p290 :004 > Date.today
=> Thu, 02 Feb 2012
ruby-1.9.2-p290 :005 > Date.tomorrow
=> Fri, 03 Feb 2012
ruby-1.9.2-p290 :006 >
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment