time_calculations 0.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/.gitignore +19 -0
- data/.rvmrc +1 -0
- data/Gemfile +4 -0
- data/Guardfile +15 -0
- data/LICENSE +22 -0
- data/README.md +41 -0
- data/Rakefile +12 -0
- data/lib/time_calculations/version.rb +3 -0
- data/lib/time_calculations.rb +44 -0
- data/spec/lib/time_calculations_spec.rb +165 -0
- data/spec/spec_helper.rb +7 -0
- data/tasks/console.rake +5 -0
- data/tasks/coverage.rake +10 -0
- data/tasks/environment.rake +4 -0
- data/tasks/spec.rake +12 -0
- data/time_calculations.gemspec +27 -0
- metadata +168 -0
data/.gitignore
ADDED
data/.rvmrc
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
rvm use ruby-1.9.3@time_calculations --create
|
data/Gemfile
ADDED
data/Guardfile
ADDED
@@ -0,0 +1,15 @@
|
|
1
|
+
# A sample Guardfile
|
2
|
+
# More info at https://github.com/guard/guard#readme
|
3
|
+
|
4
|
+
guard 'bundler' do
|
5
|
+
watch('Gemfile')
|
6
|
+
watch(%r{.+\.gemspec})
|
7
|
+
end
|
8
|
+
|
9
|
+
guard 'rspec', :cli => '-c --format documentation -r ./spec/spec_helper.rb',
|
10
|
+
:version => 2 do
|
11
|
+
watch(%r{^spec/.+_spec\.rb})
|
12
|
+
watch(%r{^lib/(.+)\.rb}) { |m| "spec/lib/#{m[1]}_spec.rb" }
|
13
|
+
watch('spec/spec_helper.rb') { "spec/" }
|
14
|
+
watch('lib/time_calculations.rb') { "spec/" }
|
15
|
+
end
|
data/LICENSE
ADDED
@@ -0,0 +1,22 @@
|
|
1
|
+
Copyright (c) 2012 Chris Johnson
|
2
|
+
|
3
|
+
MIT License
|
4
|
+
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
6
|
+
a copy of this software and associated documentation files (the
|
7
|
+
"Software"), to deal in the Software without restriction, including
|
8
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
9
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
10
|
+
permit persons to whom the Software is furnished to do so, subject to
|
11
|
+
the following conditions:
|
12
|
+
|
13
|
+
The above copyright notice and this permission notice shall be
|
14
|
+
included in all copies or substantial portions of the Software.
|
15
|
+
|
16
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
17
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
18
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
19
|
+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
20
|
+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
21
|
+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
22
|
+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
data/README.md
ADDED
@@ -0,0 +1,41 @@
|
|
1
|
+
# TimeCalculations
|
2
|
+
|
3
|
+
Extra methods for Date, Time, and DateTime.
|
4
|
+
|
5
|
+
## Installation
|
6
|
+
|
7
|
+
Add this line to your application's Gemfile:
|
8
|
+
|
9
|
+
gem 'time_calculations'
|
10
|
+
|
11
|
+
And then execute:
|
12
|
+
|
13
|
+
$ bundle
|
14
|
+
|
15
|
+
Or install it yourself as:
|
16
|
+
|
17
|
+
$ gem install time_calculations
|
18
|
+
|
19
|
+
## Usage
|
20
|
+
|
21
|
+
Time.parse('2002-02-02 02:02:02').beginning_of_hour == Time.parse('2002-02-02 02:00:00')
|
22
|
+
Time.parse('2002-02-02 02:02:02').beginning_of_minute == Time.parse('2002-02-02 02:02:00')
|
23
|
+
|
24
|
+
Time.parse('2002-02-02 02:02:02').round_up(:year) == Time.parse('2003-01-01 00:00:00')
|
25
|
+
Time.parse('2002-01-01 00:00:00').round_up(:year) == Time.parse('2002-01-01 00:00:00')
|
26
|
+
Time.parse('2002-02-02 02:02:02').round_up(:month) == Time.parse('2002-03-01 00:00:00')
|
27
|
+
Time.parse('2002-02-01 00:00:00').round_up(:month) == Time.parse('2002-02-01 00:00:00')
|
28
|
+
Time.parse('2002-02-02 02:02:02').round_up(:day) == Time.parse('2002-02-03 00:00:00')
|
29
|
+
Time.parse('2002-02-02 00:00:00').round_up(:day) == Time.parse('2002-02-02 00:00:00')
|
30
|
+
Time.parse('2002-02-02 02:02:02').round_up(:hour) == Time.parse('2002-02-02 03:00:00')
|
31
|
+
Time.parse('2002-02-02 02:00:00').round_up(:hour) == Time.parse('2002-02-02 02:00:00')
|
32
|
+
Time.parse('2002-02-02 02:02:02').round_up(:minute) == Time.parse('2002-02-02 02:03:00')
|
33
|
+
Time.parse('2002-02-02 02:02:00').round_up(:minute) == Time.parse('2002-02-02 02:02:00')
|
34
|
+
|
35
|
+
## Contributing
|
36
|
+
|
37
|
+
1. Fork it
|
38
|
+
2. Create your feature branch (`git checkout -b my-new-feature`)
|
39
|
+
3. Commit your changes (`git commit -am 'Added some feature'`)
|
40
|
+
4. Push to the branch (`git push origin my-new-feature`)
|
41
|
+
5. Create new Pull Request
|
data/Rakefile
ADDED
@@ -0,0 +1,12 @@
|
|
1
|
+
require "bundler/gem_tasks"
|
2
|
+
|
3
|
+
require 'bundler/setup'
|
4
|
+
Bundler.require(:default)
|
5
|
+
|
6
|
+
Dir['tasks/*.rake'].sort.each { |task| load task }
|
7
|
+
|
8
|
+
# Add rake tasks from selected gems
|
9
|
+
gem_names = []
|
10
|
+
gem_names.each do |gem_name|
|
11
|
+
Dir[File.join(Gem.searcher.find(gem_name).full_gem_path, '**', '*.rake')].each{|rake_file| load rake_file }
|
12
|
+
end
|
@@ -0,0 +1,44 @@
|
|
1
|
+
require "time_calculations/version"
|
2
|
+
require "active_support/core_ext"
|
3
|
+
|
4
|
+
module TimeCalculations
|
5
|
+
def beginning_of_hour
|
6
|
+
change(:min => 0, :sec => 0, :usec => 0)
|
7
|
+
end
|
8
|
+
|
9
|
+
def beginning_of_minute
|
10
|
+
change(:sec => 0, :usec => 0)
|
11
|
+
end
|
12
|
+
|
13
|
+
def round_up(what)
|
14
|
+
case what
|
15
|
+
when :year
|
16
|
+
self == beginning_of_year ? self : advance(:years => 1).beginning_of_year
|
17
|
+
when :month
|
18
|
+
self == beginning_of_month ? self : advance(:months => 1).beginning_of_month
|
19
|
+
when :day
|
20
|
+
return self unless acts_like?(:time)
|
21
|
+
self == beginning_of_day ? self : advance(:days => 1).beginning_of_day
|
22
|
+
when :hour
|
23
|
+
return self unless acts_like?(:time)
|
24
|
+
self == beginning_of_hour ? self : advance(:hours => 1).beginning_of_hour
|
25
|
+
when :minute
|
26
|
+
return self unless acts_like?(:time)
|
27
|
+
self == beginning_of_minute ? self : advance(:minutes => 1).beginning_of_minute
|
28
|
+
else
|
29
|
+
raise ArgumentError, "Don't know how to round up #{what}"
|
30
|
+
end
|
31
|
+
end
|
32
|
+
end
|
33
|
+
|
34
|
+
class Time
|
35
|
+
include TimeCalculations
|
36
|
+
end
|
37
|
+
|
38
|
+
class Date
|
39
|
+
include TimeCalculations
|
40
|
+
end
|
41
|
+
|
42
|
+
class DateTime
|
43
|
+
include TimeCalculations
|
44
|
+
end
|
@@ -0,0 +1,165 @@
|
|
1
|
+
require File.dirname(__FILE__) + '/../spec_helper'
|
2
|
+
|
3
|
+
describe TimeCalculations do
|
4
|
+
context "Date.beginning_of_hour" do
|
5
|
+
it "should convert 2002-02-02 02:02:02 to 2002-02-02 02:00:00" do
|
6
|
+
Date.parse('2002-02-02 02:02:02').beginning_of_hour.should == Date.parse('2002-02-02 02:00:00')
|
7
|
+
end
|
8
|
+
|
9
|
+
it "should convert 2002-02-02 02:00:00 to 2002-02-02 02:00:00" do
|
10
|
+
Date.parse('2002-02-02 02:00:00').beginning_of_hour.should == Date.parse('2002-02-02 02:00:00')
|
11
|
+
end
|
12
|
+
end
|
13
|
+
|
14
|
+
context "Time.beginning_of_hour" do
|
15
|
+
it "should convert 2002-02-02 02:02:02 to 2002-02-02 02:00:00" do
|
16
|
+
Time.parse('2002-02-02 02:02:02').beginning_of_hour.should == Time.parse('2002-02-02 02:00:00')
|
17
|
+
end
|
18
|
+
|
19
|
+
it "should convert 2002-02-02 02:00:00 to 2002-02-02 02:00:00" do
|
20
|
+
Time.parse('2002-02-02 02:00:00').beginning_of_hour.should == Time.parse('2002-02-02 02:00:00')
|
21
|
+
end
|
22
|
+
end
|
23
|
+
|
24
|
+
context "DateTime.beginning_of_hour" do
|
25
|
+
it "should convert 2002-02-02 02:02:02 to 2002-02-02 02:00:00" do
|
26
|
+
DateTime.parse('2002-02-02 02:02:02').beginning_of_hour.should == DateTime.parse('2002-02-02 02:00:00')
|
27
|
+
end
|
28
|
+
|
29
|
+
it "should convert 2002-02-02 02:00:00 to 2002-02-02 02:00:00" do
|
30
|
+
DateTime.parse('2002-02-02 02:00:00').beginning_of_hour.should == DateTime.parse('2002-02-02 02:00:00')
|
31
|
+
end
|
32
|
+
end
|
33
|
+
|
34
|
+
context "Date.beginning_of_minute" do
|
35
|
+
it "should convert 2002-02-02 02:02:02 to 2002-02-02 02:02:00" do
|
36
|
+
Date.parse('2002-02-02 02:02:02').beginning_of_minute.should == Date.parse('2002-02-02 02:02:00')
|
37
|
+
end
|
38
|
+
|
39
|
+
it "should convert 2002-02-02 02:02:00 to 2002-02-02 02:02:00" do
|
40
|
+
Date.parse('2002-02-02 02:02:00').beginning_of_minute.should == Date.parse('2002-02-02 02:02:00')
|
41
|
+
end
|
42
|
+
end
|
43
|
+
|
44
|
+
context "Time.beginning_of_minute" do
|
45
|
+
it "should convert 2002-02-02 02:02:02 to 2002-02-02 02:02:00" do
|
46
|
+
Time.parse('2002-02-02 02:02:02').beginning_of_minute.should == Time.parse('2002-02-02 02:02:00')
|
47
|
+
end
|
48
|
+
|
49
|
+
it "should convert 2002-02-02 02:02:00 to 2002-02-02 02:02:00" do
|
50
|
+
Time.parse('2002-02-02 02:02:00').beginning_of_minute.should == Time.parse('2002-02-02 02:02:00')
|
51
|
+
end
|
52
|
+
end
|
53
|
+
|
54
|
+
context "DateTime.beginning_of_minute" do
|
55
|
+
it "should convert 2002-02-02 02:02:02 to 2002-02-02 02:02:00" do
|
56
|
+
DateTime.parse('2002-02-02 02:02:02').beginning_of_minute.should == DateTime.parse('2002-02-02 02:02:00')
|
57
|
+
end
|
58
|
+
|
59
|
+
it "should convert 2002-02-02 02:02:00 to 2002-02-02 02:02:00" do
|
60
|
+
DateTime.parse('2002-02-02 02:02:00').beginning_of_minute.should == DateTime.parse('2002-02-02 02:02:00')
|
61
|
+
end
|
62
|
+
end
|
63
|
+
|
64
|
+
context "Date.round_up(:year)" do
|
65
|
+
it "should convert 2002-02-02 02:02:02 to 2003-01-01 00:00:00" do
|
66
|
+
Date.parse('2002-02-02 02:02:02').round_up(:year).should == Date.parse('2003-01-01 00:00:00')
|
67
|
+
end
|
68
|
+
it "should convert 2003-01-01 00:00:00 to 2003-01-01 00:00:00" do
|
69
|
+
Date.parse('2003-01-01 00:00:00').round_up(:year).should == Date.parse('2003-01-01 00:00:00')
|
70
|
+
end
|
71
|
+
end
|
72
|
+
context "Time.round_up(:year)" do
|
73
|
+
it "should convert 2002-02-02 02:02:02 to 2003-01-01 00:00:00" do
|
74
|
+
Time.parse('2002-02-02 02:02:02').round_up(:year).should == Time.parse('2003-01-01 00:00:00')
|
75
|
+
end
|
76
|
+
it "should convert 2003-01-01 00:00:00 to 2003-01-01 00:00:00" do
|
77
|
+
Time.parse('2003-01-01 00:00:00').round_up(:year).should == Time.parse('2003-01-01 00:00:00')
|
78
|
+
end
|
79
|
+
end
|
80
|
+
context "DateTime.round_up(:year)" do
|
81
|
+
it "should convert 2002-02-02 02:02:02 to 2003-01-01 00:00:00" do
|
82
|
+
DateTime.parse('2002-02-02 02:02:02').round_up(:year).should == DateTime.parse('2003-01-01 00:00:00')
|
83
|
+
end
|
84
|
+
it "should convert 2003-01-01 00:00:00 to 2003-01-01 00:00:00" do
|
85
|
+
DateTime.parse('2003-01-01 00:00:00').round_up(:year).should == DateTime.parse('2003-01-01 00:00:00')
|
86
|
+
end
|
87
|
+
end
|
88
|
+
|
89
|
+
context "Date.round_up(:month)" do
|
90
|
+
it "should convert 2002-02-02 02:02:02 to 2002-03-01 00:00:00" do
|
91
|
+
Date.parse('2002-02-02 02:02:02').round_up(:month).should == Date.parse('2002-03-01 00:00:00')
|
92
|
+
end
|
93
|
+
it "should convert 2002-03-01 00:00:00 to 2002-03-01 00:00:00" do
|
94
|
+
Date.parse('2002-03-01 00:00:00').round_up(:month).should == Date.parse('2002-03-01 00:00:00')
|
95
|
+
end
|
96
|
+
end
|
97
|
+
context "Time.round_up(:month)" do
|
98
|
+
it "should convert 2002-02-02 02:02:02 to 2002-03-01 00:00:00" do
|
99
|
+
Time.parse('2002-02-02 02:02:02').round_up(:month).should == Time.parse('2002-03-01 00:00:00')
|
100
|
+
end
|
101
|
+
it "should convert 2002-03-01 00:00:00 to 2002-03-01 00:00:00" do
|
102
|
+
Time.parse('2002-03-01 00:00:00').round_up(:month).should == Time.parse('2002-03-01 00:00:00')
|
103
|
+
end
|
104
|
+
end
|
105
|
+
context "DateTime.round_up(:month)" do
|
106
|
+
it "should convert 2002-02-02 02:02:02 to 2002-03-01 00:00:00" do
|
107
|
+
DateTime.parse('2002-02-02 02:02:02').round_up(:month).should == DateTime.parse('2002-03-01 00:00:00')
|
108
|
+
end
|
109
|
+
it "should convert 2002-03-01 00:00:00 to 2002-03-01 00:00:00" do
|
110
|
+
DateTime.parse('2002-03-01 00:00:00').round_up(:month).should == DateTime.parse('2002-03-01 00:00:00')
|
111
|
+
end
|
112
|
+
end
|
113
|
+
|
114
|
+
context "Time.round_up(:day)" do
|
115
|
+
it "should convert 2002-02-02 02:02:02 to 2002-02-03 00:00:00" do
|
116
|
+
Time.parse('2002-02-02 02:02:02').round_up(:day).should == Time.parse('2002-02-03 00:00:00')
|
117
|
+
end
|
118
|
+
it "should convert 2002-02-03 00:00:00 to 2002-02-03 00:00:00" do
|
119
|
+
Time.parse('2002-02-03 00:00:00').round_up(:day).should == Time.parse('2002-02-03 00:00:00')
|
120
|
+
end
|
121
|
+
end
|
122
|
+
context "DateTime.round_up(:day)" do
|
123
|
+
it "should convert 2002-02-02 02:02:02 to 2002-02-03 00:00:00" do
|
124
|
+
DateTime.parse('2002-02-02 02:02:02').round_up(:day).should == DateTime.parse('2002-02-03 00:00:00')
|
125
|
+
end
|
126
|
+
it "should convert 2002-02-03 00:00:00 to 2002-02-03 00:00:00" do
|
127
|
+
DateTime.parse('2002-02-03 00:00:00').round_up(:day).should == DateTime.parse('2002-02-03 00:00:00')
|
128
|
+
end
|
129
|
+
end
|
130
|
+
|
131
|
+
context "Time.round_up(:hour)" do
|
132
|
+
it "should convert 2002-02-02 02:02:02 to 2002-02-02 03:00:00" do
|
133
|
+
Time.parse('2002-02-02 02:02:02').round_up(:hour).should == Time.parse('2002-02-02 03:00:00')
|
134
|
+
end
|
135
|
+
it "should convert 2002-02-02 03:00:00 to 2002-02-02 03:00:00" do
|
136
|
+
Time.parse('2002-02-02 03:00:00').round_up(:hour).should == Time.parse('2002-02-02 03:00:00')
|
137
|
+
end
|
138
|
+
end
|
139
|
+
context "DateTime.round_up(:hour)" do
|
140
|
+
it "should convert 2002-02-02 02:02:02 to 2002-02-02 03:00:00" do
|
141
|
+
DateTime.parse('2002-02-02 02:02:02').round_up(:hour).should == DateTime.parse('2002-02-02 03:00:00')
|
142
|
+
end
|
143
|
+
it "should convert 2002-02-02 03:00:00 to 2002-02-02 03:00:00" do
|
144
|
+
DateTime.parse('2002-02-02 03:00:00').round_up(:hour).should == DateTime.parse('2002-02-02 03:00:00')
|
145
|
+
end
|
146
|
+
end
|
147
|
+
|
148
|
+
context "Time.round_up(:minute)" do
|
149
|
+
it "should convert 2002-02-02 02:02:02 to 2002-02-02 02:03:00" do
|
150
|
+
Time.parse('2002-02-02 02:02:02').round_up(:minute).should == Time.parse('2002-02-02 02:03:00')
|
151
|
+
end
|
152
|
+
it "should convert 2002-02-02 02:03:00 to 2002-02-02 02:03:00" do
|
153
|
+
Time.parse('2002-02-02 02:03:00').round_up(:minute).should == Time.parse('2002-02-02 02:03:00')
|
154
|
+
end
|
155
|
+
end
|
156
|
+
context "DateTime.round_up(:minute)" do
|
157
|
+
it "should convert 2002-02-02 02:02:02 to 2002-02-02 02:03:00" do
|
158
|
+
DateTime.parse('2002-02-02 02:02:02').round_up(:minute).should == DateTime.parse('2002-02-02 02:03:00')
|
159
|
+
end
|
160
|
+
it "should convert 2002-02-02 02:03:00 to 2002-02-02 02:03:00" do
|
161
|
+
DateTime.parse('2002-02-02 02:03:00').round_up(:minute).should == DateTime.parse('2002-02-02 02:03:00')
|
162
|
+
end
|
163
|
+
end
|
164
|
+
|
165
|
+
end
|
data/spec/spec_helper.rb
ADDED
data/tasks/console.rake
ADDED
data/tasks/coverage.rake
ADDED
data/tasks/spec.rake
ADDED
@@ -0,0 +1,27 @@
|
|
1
|
+
# -*- encoding: utf-8 -*-
|
2
|
+
require File.expand_path('../lib/time_calculations/version', __FILE__)
|
3
|
+
|
4
|
+
Gem::Specification.new do |gem|
|
5
|
+
gem.authors = ["Chris Johnson"]
|
6
|
+
gem.email = ["chris@kindkid.com"]
|
7
|
+
gem.description = "Extra methods for Date, Time, and DateTime"
|
8
|
+
gem.summary = gem.description
|
9
|
+
gem.homepage = "http://github.com/kindkid/time_calculations"
|
10
|
+
|
11
|
+
gem.files = `git ls-files`.split($\)
|
12
|
+
gem.executables = gem.files.grep(%r{^bin/}).map{ |f| File.basename(f) }
|
13
|
+
gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
|
14
|
+
gem.name = "time_calculations"
|
15
|
+
gem.require_paths = ["lib"]
|
16
|
+
gem.version = TimeCalculations::VERSION
|
17
|
+
gem.add_dependency "active_support", "~> 3.0.0"
|
18
|
+
gem.add_dependency "i18n"
|
19
|
+
|
20
|
+
gem.add_development_dependency "rspec", "~> 2.10.0"
|
21
|
+
gem.add_development_dependency "simplecov", "~> 0.6.4"
|
22
|
+
gem.add_development_dependency("rb-fsevent", "~> 0.9.1") if RUBY_PLATFORM =~ /darwin/i
|
23
|
+
gem.add_development_dependency "guard", "~> 1.1.1"
|
24
|
+
gem.add_development_dependency "guard-bundler", "~> 0.1.3"
|
25
|
+
gem.add_development_dependency "guard-rspec", "~> 1.0.0"
|
26
|
+
gem.add_development_dependency "timecop", "~> 0.3.5"
|
27
|
+
end
|
metadata
ADDED
@@ -0,0 +1,168 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: time_calculations
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.0.1
|
5
|
+
prerelease:
|
6
|
+
platform: ruby
|
7
|
+
authors:
|
8
|
+
- Chris Johnson
|
9
|
+
autorequire:
|
10
|
+
bindir: bin
|
11
|
+
cert_chain: []
|
12
|
+
date: 2012-06-05 00:00:00.000000000 Z
|
13
|
+
dependencies:
|
14
|
+
- !ruby/object:Gem::Dependency
|
15
|
+
name: active_support
|
16
|
+
requirement: &70275368192480 !ruby/object:Gem::Requirement
|
17
|
+
none: false
|
18
|
+
requirements:
|
19
|
+
- - ~>
|
20
|
+
- !ruby/object:Gem::Version
|
21
|
+
version: 3.0.0
|
22
|
+
type: :runtime
|
23
|
+
prerelease: false
|
24
|
+
version_requirements: *70275368192480
|
25
|
+
- !ruby/object:Gem::Dependency
|
26
|
+
name: i18n
|
27
|
+
requirement: &70275368192040 !ruby/object:Gem::Requirement
|
28
|
+
none: false
|
29
|
+
requirements:
|
30
|
+
- - ! '>='
|
31
|
+
- !ruby/object:Gem::Version
|
32
|
+
version: '0'
|
33
|
+
type: :runtime
|
34
|
+
prerelease: false
|
35
|
+
version_requirements: *70275368192040
|
36
|
+
- !ruby/object:Gem::Dependency
|
37
|
+
name: rspec
|
38
|
+
requirement: &70275368191460 !ruby/object:Gem::Requirement
|
39
|
+
none: false
|
40
|
+
requirements:
|
41
|
+
- - ~>
|
42
|
+
- !ruby/object:Gem::Version
|
43
|
+
version: 2.10.0
|
44
|
+
type: :development
|
45
|
+
prerelease: false
|
46
|
+
version_requirements: *70275368191460
|
47
|
+
- !ruby/object:Gem::Dependency
|
48
|
+
name: simplecov
|
49
|
+
requirement: &70275368190820 !ruby/object:Gem::Requirement
|
50
|
+
none: false
|
51
|
+
requirements:
|
52
|
+
- - ~>
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: 0.6.4
|
55
|
+
type: :development
|
56
|
+
prerelease: false
|
57
|
+
version_requirements: *70275368190820
|
58
|
+
- !ruby/object:Gem::Dependency
|
59
|
+
name: rb-fsevent
|
60
|
+
requirement: &70275368190120 !ruby/object:Gem::Requirement
|
61
|
+
none: false
|
62
|
+
requirements:
|
63
|
+
- - ~>
|
64
|
+
- !ruby/object:Gem::Version
|
65
|
+
version: 0.9.1
|
66
|
+
type: :development
|
67
|
+
prerelease: false
|
68
|
+
version_requirements: *70275368190120
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: guard
|
71
|
+
requirement: &70275368189380 !ruby/object:Gem::Requirement
|
72
|
+
none: false
|
73
|
+
requirements:
|
74
|
+
- - ~>
|
75
|
+
- !ruby/object:Gem::Version
|
76
|
+
version: 1.1.1
|
77
|
+
type: :development
|
78
|
+
prerelease: false
|
79
|
+
version_requirements: *70275368189380
|
80
|
+
- !ruby/object:Gem::Dependency
|
81
|
+
name: guard-bundler
|
82
|
+
requirement: &70275368188540 !ruby/object:Gem::Requirement
|
83
|
+
none: false
|
84
|
+
requirements:
|
85
|
+
- - ~>
|
86
|
+
- !ruby/object:Gem::Version
|
87
|
+
version: 0.1.3
|
88
|
+
type: :development
|
89
|
+
prerelease: false
|
90
|
+
version_requirements: *70275368188540
|
91
|
+
- !ruby/object:Gem::Dependency
|
92
|
+
name: guard-rspec
|
93
|
+
requirement: &70275368187520 !ruby/object:Gem::Requirement
|
94
|
+
none: false
|
95
|
+
requirements:
|
96
|
+
- - ~>
|
97
|
+
- !ruby/object:Gem::Version
|
98
|
+
version: 1.0.0
|
99
|
+
type: :development
|
100
|
+
prerelease: false
|
101
|
+
version_requirements: *70275368187520
|
102
|
+
- !ruby/object:Gem::Dependency
|
103
|
+
name: timecop
|
104
|
+
requirement: &70275368186640 !ruby/object:Gem::Requirement
|
105
|
+
none: false
|
106
|
+
requirements:
|
107
|
+
- - ~>
|
108
|
+
- !ruby/object:Gem::Version
|
109
|
+
version: 0.3.5
|
110
|
+
type: :development
|
111
|
+
prerelease: false
|
112
|
+
version_requirements: *70275368186640
|
113
|
+
description: Extra methods for Date, Time, and DateTime
|
114
|
+
email:
|
115
|
+
- chris@kindkid.com
|
116
|
+
executables: []
|
117
|
+
extensions: []
|
118
|
+
extra_rdoc_files: []
|
119
|
+
files:
|
120
|
+
- .gitignore
|
121
|
+
- .rvmrc
|
122
|
+
- Gemfile
|
123
|
+
- Guardfile
|
124
|
+
- LICENSE
|
125
|
+
- README.md
|
126
|
+
- Rakefile
|
127
|
+
- lib/time_calculations.rb
|
128
|
+
- lib/time_calculations/version.rb
|
129
|
+
- spec/lib/time_calculations_spec.rb
|
130
|
+
- spec/spec_helper.rb
|
131
|
+
- tasks/console.rake
|
132
|
+
- tasks/coverage.rake
|
133
|
+
- tasks/environment.rake
|
134
|
+
- tasks/spec.rake
|
135
|
+
- time_calculations.gemspec
|
136
|
+
homepage: http://github.com/kindkid/time_calculations
|
137
|
+
licenses: []
|
138
|
+
post_install_message:
|
139
|
+
rdoc_options: []
|
140
|
+
require_paths:
|
141
|
+
- lib
|
142
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
143
|
+
none: false
|
144
|
+
requirements:
|
145
|
+
- - ! '>='
|
146
|
+
- !ruby/object:Gem::Version
|
147
|
+
version: '0'
|
148
|
+
segments:
|
149
|
+
- 0
|
150
|
+
hash: 4423109232132138429
|
151
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
152
|
+
none: false
|
153
|
+
requirements:
|
154
|
+
- - ! '>='
|
155
|
+
- !ruby/object:Gem::Version
|
156
|
+
version: '0'
|
157
|
+
segments:
|
158
|
+
- 0
|
159
|
+
hash: 4423109232132138429
|
160
|
+
requirements: []
|
161
|
+
rubyforge_project:
|
162
|
+
rubygems_version: 1.8.10
|
163
|
+
signing_key:
|
164
|
+
specification_version: 3
|
165
|
+
summary: Extra methods for Date, Time, and DateTime
|
166
|
+
test_files:
|
167
|
+
- spec/lib/time_calculations_spec.rb
|
168
|
+
- spec/spec_helper.rb
|