Sha256: 70896cce745876f2d23b304b79c970f57bfb27425f7df2e5a25724ff6bdcb14f
Contents?: true
Size: 1.52 KB
Versions: 1
Compression:
Stored size: 1.52 KB
Contents
= tempus {<img src="https://badge.fury.io/rb/tempus.png" alt="Gem Version" />}[http://badge.fury.io/rb/tempus] Gem to efficiently manipulate the time, adding, subtracting and converting hours. == EXAMPLE USAGE hours = Tempus.new(30.hours + 5.minutes + 3.seconds) => <Tempus:8508680 seconds=108303.0, formated=30:05:03> hours.value_in_minutes => 1805.05 hours.to_s("%H hours and %M minutes") => "30 hours and 05 minutes" hours = "35:05:01".to_tempus => <Tempus:7228060 seconds=126301.0, formated=35:05:01> hours + 6.hours => <Tempus:6931320 seconds=147901.0, formated=41:05:01> "1:00:00".to_tempus + "2:00" => <Tempus:6634700 seconds=10800.0, formated=03:00:00> Tempus.new Time.now => <Tempus:6578680 seconds=46455.162950918, formated=12:54:15> == Contributing to tempus * Check out the latest master to make sure the feature hasn't been implemented or the bug hasn't been fixed yet. * Check out the issue tracker to make sure someone already hasn't requested it and/or contributed it. * Fork the project. * Start a feature/bugfix branch. * Commit and push until you are happy with your contribution. * Make sure to add tests for it. This is important so I don't break it in a future version unintentionally. * Please try not to mess with the Rakefile, version, or history. If you want to have your own version, or is otherwise necessary, that is fine, but please isolate to its own commit so I can cherry-pick around it. == Copyright Copyright (c) 2012 Danilo Jeremias da Silva. See LICENSE.txt for further details.
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
tempus-0.2.0 | README.rdoc |