Created
April 10, 2013 15:19
-
-
Save pdswan/5355552 to your computer and use it in GitHub Desktop.
Forcing jruby to use UTC for everything
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
ENV['TZ'] = 'UTC' | |
if RUBY_PLATFORM =~ /java/ | |
org.joda.time.DateTimeZone.setDefault(org.joda.time.DateTimeZone::UTC) | |
java.util.TimeZone.setDefault(java.util.TimeZone.getTimeZone('UTC')) | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment