TZInfo - Ruby Time Zone Library

RubyGems: tzinfo Tests: tzinfo RubyGems: tzinfo-data

TZInfo is a Ruby library that provides access to time zone data and allows times to be converted using time zone rules.

Data Sources

TZInfo requires a source of timezone data. There are two options:

  1. A zoneinfo directory containing timezone definition files. These files are generated from the IANA Time Zone Database using the zic utility. Most Unix-like systems include a zoneinfo directory.
  2. The TZInfo::Data library (the tzinfo-data gem). TZInfo::Data contains a set of Ruby modules that are also generated from the IANA Time Zone Database.

By default, TZInfo will attempt to use TZInfo::Data. If TZInfo::Data is not available, then TZInfo will search for a zoneinfo directory instead.

Custom data sources can also be created and used with TZInfo.

RubyGems

gem files are available on RubyGems.org:

Installation and Usage

Instructions for installing and using TZInfo can be found in the project readme file.

Documentation

API Documentation for TZInfo is available on RubyDoc.info.

License

TZInfo and TZInfo::Data are released under the MIT license. Please refer to the license files (TZInfo, TZInfo::Data) for details.

Source Code

Source code for TZInfo and TZInfo::Data is available on GitHub:

Issue Tracker

Please post any bugs, issues, feature requests or questions about TZInfo to the GitHub issue tracker. Issues with the underlying time zone data should be raised on the Time Zone Database Discussion mailing list.

Releases

Information about releases can be found on GitHub:

Phil Ross
7 January 2021