kronos 0.1.8 → 0.1.9
Sign up to get free protection for your applications and to get access to all the features.
- data/.bundle/config +2 -0
- data/Gemfile +7 -0
- data/Gemfile.lock +31 -0
- data/LICENSE +1 -1
- data/Rakefile +20 -39
- data/kronos.gemspec +25 -27
- data/lib/kronos.rb +30 -24
- data/lib/version.rb +11 -0
- data/spec/compare_spec.rb +9 -9
- data/spec/from_hash_spec.rb +5 -4
- data/spec/parse_spec.rb +8 -8
- data/spec/spec_helper.rb +6 -8
- data/spec/to_s_spec.rb +2 -2
- data/spec/valid_spec.rb +35 -11
- metadata +61 -15
- data/.gitignore +0 -21
- data/VERSION +0 -1
data/.bundle/config
ADDED
data/Gemfile
ADDED
data/Gemfile.lock
ADDED
@@ -0,0 +1,31 @@
|
|
1
|
+
PATH
|
2
|
+
remote: .
|
3
|
+
specs:
|
4
|
+
kronos (0.1.9)
|
5
|
+
|
6
|
+
GEM
|
7
|
+
remote: http://rubygems.org/
|
8
|
+
specs:
|
9
|
+
diff-lcs (1.1.2)
|
10
|
+
git (1.2.5)
|
11
|
+
jeweler (1.5.1)
|
12
|
+
bundler (~> 1.0.0)
|
13
|
+
git (>= 1.2.5)
|
14
|
+
rake
|
15
|
+
rake (0.8.7)
|
16
|
+
rspec (2.2.0)
|
17
|
+
rspec-core (~> 2.2)
|
18
|
+
rspec-expectations (~> 2.2)
|
19
|
+
rspec-mocks (~> 2.2)
|
20
|
+
rspec-core (2.2.1)
|
21
|
+
rspec-expectations (2.2.0)
|
22
|
+
diff-lcs (~> 1.1.2)
|
23
|
+
rspec-mocks (2.2.0)
|
24
|
+
|
25
|
+
PLATFORMS
|
26
|
+
ruby
|
27
|
+
|
28
|
+
DEPENDENCIES
|
29
|
+
jeweler (~> 1.5.1)
|
30
|
+
kronos!
|
31
|
+
rspec (~> 2.2)
|
data/LICENSE
CHANGED
data/Rakefile
CHANGED
@@ -1,45 +1,26 @@
|
|
1
1
|
require 'rubygems'
|
2
2
|
require 'rake'
|
3
3
|
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
puts "Jeweler (or a dependency) not available. Install it with: gem install jeweler"
|
4
|
+
require 'jeweler'
|
5
|
+
require File.expand_path('../lib/version', __FILE__)
|
6
|
+
Jeweler::Tasks.new do |gem|
|
7
|
+
gem.name = "kronos"
|
8
|
+
gem.version = Kronos::Version::STRING
|
9
|
+
gem.summary = %Q{Simple and flexible date parsing.}
|
10
|
+
gem.description = %Q{Kronos provides flexible date parsing. Currently just a thin layer on top of ParseDate.}
|
11
|
+
gem.email = "djames@sunlightfoundation.com"
|
12
|
+
gem.homepage = "http://github.com/djsun/kronos"
|
13
|
+
gem.authors = ["David James"]
|
14
|
+
gem.add_development_dependency "rspec", "~> 2.2"
|
15
|
+
gem.rubyforge_project = 'kronos'
|
16
|
+
# gem is a Gem::Specification
|
17
|
+
# see http://www.rubygems.org/read/chapter/20 for additional settings
|
19
18
|
end
|
20
19
|
|
21
|
-
require '
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
Spec::Rake::SpecTask.new(:rcov) do |spec|
|
28
|
-
spec.libs << 'lib' << 'spec'
|
29
|
-
spec.pattern = 'spec/**/*_spec.rb'
|
30
|
-
spec.rcov = true
|
31
|
-
end
|
32
|
-
|
33
|
-
task :spec => :check_dependencies
|
34
|
-
|
35
|
-
task :default => :spec
|
36
|
-
|
37
|
-
require 'rake/rdoctask'
|
38
|
-
Rake::RDocTask.new do |rdoc|
|
39
|
-
version = File.exist?('VERSION') ? File.read('VERSION') : ""
|
40
|
-
|
41
|
-
rdoc.rdoc_dir = 'rdoc'
|
42
|
-
rdoc.title = "kronos #{version}"
|
43
|
-
rdoc.rdoc_files.include('README*')
|
44
|
-
rdoc.rdoc_files.include('lib/**/*.rb')
|
20
|
+
require 'rspec/core/rake_task'
|
21
|
+
desc "Run specs"
|
22
|
+
RSpec::Core::RakeTask.new do |t|
|
23
|
+
t.rspec_opts = %w(--color)
|
24
|
+
# t.rspec_opts = %w(-fs --color)
|
25
|
+
# t.ruby_opts = %w(-w)
|
45
26
|
end
|
data/kronos.gemspec
CHANGED
@@ -1,50 +1,48 @@
|
|
1
1
|
# Generated by jeweler
|
2
2
|
# DO NOT EDIT THIS FILE DIRECTLY
|
3
|
-
# Instead, edit Jeweler::Tasks in Rakefile, and run
|
3
|
+
# Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
|
4
4
|
# -*- encoding: utf-8 -*-
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{kronos}
|
8
|
-
s.version = "0.1.
|
8
|
+
s.version = "0.1.9"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["David James"]
|
12
|
-
s.date = %q{2010-10
|
12
|
+
s.date = %q{2010-12-10}
|
13
13
|
s.description = %q{Kronos provides flexible date parsing. Currently just a thin layer on top of ParseDate.}
|
14
14
|
s.email = %q{djames@sunlightfoundation.com}
|
15
15
|
s.extra_rdoc_files = [
|
16
16
|
"LICENSE",
|
17
|
-
|
17
|
+
"README.md"
|
18
18
|
]
|
19
19
|
s.files = [
|
20
20
|
".document",
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
"spec/to_s_spec.rb",
|
34
|
-
"spec/valid_spec.rb"
|
21
|
+
"LICENSE",
|
22
|
+
"README.md",
|
23
|
+
"Rakefile",
|
24
|
+
"kronos.gemspec",
|
25
|
+
"lib/kronos.rb",
|
26
|
+
"spec/compare_spec.rb",
|
27
|
+
"spec/from_hash_spec.rb",
|
28
|
+
"spec/parse_spec.rb",
|
29
|
+
"spec/spec.opts",
|
30
|
+
"spec/spec_helper.rb",
|
31
|
+
"spec/to_s_spec.rb",
|
32
|
+
"spec/valid_spec.rb"
|
35
33
|
]
|
36
34
|
s.homepage = %q{http://github.com/djsun/kronos}
|
37
|
-
s.rdoc_options = ["--charset=UTF-8"]
|
38
35
|
s.require_paths = ["lib"]
|
36
|
+
s.rubyforge_project = %q{kronos}
|
39
37
|
s.rubygems_version = %q{1.3.7}
|
40
38
|
s.summary = %q{Simple and flexible date parsing.}
|
41
39
|
s.test_files = [
|
42
40
|
"spec/compare_spec.rb",
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
41
|
+
"spec/from_hash_spec.rb",
|
42
|
+
"spec/parse_spec.rb",
|
43
|
+
"spec/spec_helper.rb",
|
44
|
+
"spec/to_s_spec.rb",
|
45
|
+
"spec/valid_spec.rb"
|
48
46
|
]
|
49
47
|
|
50
48
|
if s.respond_to? :specification_version then
|
@@ -52,12 +50,12 @@ Gem::Specification.new do |s|
|
|
52
50
|
s.specification_version = 3
|
53
51
|
|
54
52
|
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
|
55
|
-
s.add_development_dependency(%q<rspec>, ["
|
53
|
+
s.add_development_dependency(%q<rspec>, ["~> 2.2"])
|
56
54
|
else
|
57
|
-
s.add_dependency(%q<rspec>, ["
|
55
|
+
s.add_dependency(%q<rspec>, ["~> 2.2"])
|
58
56
|
end
|
59
57
|
else
|
60
|
-
s.add_dependency(%q<rspec>, ["
|
58
|
+
s.add_dependency(%q<rspec>, ["~> 2.2"])
|
61
59
|
end
|
62
60
|
end
|
63
61
|
|
data/lib/kronos.rb
CHANGED
@@ -1,11 +1,12 @@
|
|
1
|
+
require File.expand_path("../version", __FILE__)
|
1
2
|
require 'parsedate'
|
2
3
|
|
3
4
|
class Kronos
|
4
|
-
|
5
|
+
|
5
6
|
attr_accessor :year, :month, :day
|
6
|
-
|
7
|
+
|
7
8
|
IGNORE_PATTERN = Regexp.compile("^prior")
|
8
|
-
|
9
|
+
|
9
10
|
def parse(string)
|
10
11
|
if string.nil? || string =~ IGNORE_PATTERN
|
11
12
|
nil # do nothing
|
@@ -29,7 +30,7 @@ class Kronos
|
|
29
30
|
end
|
30
31
|
self
|
31
32
|
end
|
32
|
-
|
33
|
+
|
33
34
|
def to_s
|
34
35
|
s = ""
|
35
36
|
raise "Invalid" unless valid?
|
@@ -38,17 +39,22 @@ class Kronos
|
|
38
39
|
s << "-%02i" % day if day
|
39
40
|
s
|
40
41
|
end
|
41
|
-
|
42
|
+
|
42
43
|
def valid?
|
43
|
-
if day && (!month || !year)
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
44
|
+
return false if day && (!month || !year)
|
45
|
+
return false if month && !year
|
46
|
+
return false if !year
|
47
|
+
return false if year && !((1970 .. 2069) === year)
|
48
|
+
return false if month && !((1 .. 12) === month)
|
49
|
+
return false if day && !((1 .. 31) === day)
|
50
|
+
if year && month && day
|
51
|
+
begin
|
52
|
+
Date.new(year, month, day)
|
53
|
+
rescue ArgumentError
|
54
|
+
return false
|
55
|
+
end
|
51
56
|
end
|
57
|
+
true
|
52
58
|
end
|
53
59
|
|
54
60
|
def <(other)
|
@@ -82,21 +88,21 @@ class Kronos
|
|
82
88
|
raise "Unexpected"
|
83
89
|
end
|
84
90
|
end
|
85
|
-
|
91
|
+
|
86
92
|
def <=(other)
|
87
93
|
(self < other) || (self == other)
|
88
94
|
end
|
89
|
-
|
95
|
+
|
90
96
|
def ==(other)
|
91
97
|
self.year == other.year &&
|
92
98
|
self.month == other.month &&
|
93
99
|
self.day == other.day
|
94
100
|
end
|
95
|
-
|
101
|
+
|
96
102
|
def >=(other)
|
97
103
|
(self > other) || (self == other)
|
98
104
|
end
|
99
|
-
|
105
|
+
|
100
106
|
def >(other)
|
101
107
|
if !self.year || !other.year
|
102
108
|
false
|
@@ -128,7 +134,7 @@ class Kronos
|
|
128
134
|
raise "Unexpected"
|
129
135
|
end
|
130
136
|
end
|
131
|
-
|
137
|
+
|
132
138
|
def to_hash
|
133
139
|
h = {}
|
134
140
|
h['year'] = year if year
|
@@ -136,7 +142,7 @@ class Kronos
|
|
136
142
|
h['day'] = day if day
|
137
143
|
h
|
138
144
|
end
|
139
|
-
|
145
|
+
|
140
146
|
def self.from_hash(h)
|
141
147
|
o = self.new
|
142
148
|
o.year = h['year'] if h['year']
|
@@ -144,13 +150,13 @@ class Kronos
|
|
144
150
|
o.day = h['day'] if h['day']
|
145
151
|
o if o.valid?
|
146
152
|
end
|
147
|
-
|
153
|
+
|
148
154
|
def self.parse(string)
|
149
155
|
self.new.parse(string)
|
150
156
|
end
|
151
|
-
|
157
|
+
|
152
158
|
protected
|
153
|
-
|
159
|
+
|
154
160
|
def to_full_year(x)
|
155
161
|
case x
|
156
162
|
when (0 .. 69) then 2000 + x
|
@@ -158,5 +164,5 @@ class Kronos
|
|
158
164
|
else x
|
159
165
|
end
|
160
166
|
end
|
161
|
-
|
162
|
-
end
|
167
|
+
|
168
|
+
end
|
data/lib/version.rb
ADDED
data/spec/compare_spec.rb
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
require File.expand_path(File.dirname(__FILE__) + '/spec_helper')
|
2
2
|
|
3
3
|
describe "Kronos Comparisons" do
|
4
|
-
|
4
|
+
|
5
5
|
def new_kronos(year=nil, month=nil, day=nil)
|
6
6
|
k = Kronos.new
|
7
7
|
k.year = year if year
|
@@ -9,7 +9,7 @@ describe "Kronos Comparisons" do
|
|
9
9
|
k.day = day if day
|
10
10
|
k
|
11
11
|
end
|
12
|
-
|
12
|
+
|
13
13
|
describe "2005 vs 2005" do
|
14
14
|
before do
|
15
15
|
@k1 = new_kronos(2005)
|
@@ -37,7 +37,7 @@ describe "Kronos Comparisons" do
|
|
37
37
|
end
|
38
38
|
|
39
39
|
end
|
40
|
-
|
40
|
+
|
41
41
|
describe "2005 vs 2006" do
|
42
42
|
before do
|
43
43
|
@k1 = new_kronos(2005)
|
@@ -199,29 +199,29 @@ describe "Kronos Comparisons" do
|
|
199
199
|
(@k1 >= @k2).should == true
|
200
200
|
end
|
201
201
|
end
|
202
|
-
|
202
|
+
|
203
203
|
describe "(blank) vs 2000" do
|
204
204
|
before do
|
205
205
|
@k1 = new_kronos()
|
206
206
|
@k2 = new_kronos(2000)
|
207
207
|
end
|
208
|
-
|
208
|
+
|
209
209
|
it "should not be <" do
|
210
210
|
(@k1 < @k2).should == false
|
211
211
|
end
|
212
|
-
|
212
|
+
|
213
213
|
it "should not be <=" do
|
214
214
|
(@k1 <= @k2).should == false
|
215
215
|
end
|
216
|
-
|
216
|
+
|
217
217
|
it "should not be ==" do
|
218
218
|
(@k1 == @k2).should == false
|
219
219
|
end
|
220
|
-
|
220
|
+
|
221
221
|
it "should not be >" do
|
222
222
|
(@k1 > @k2).should == false
|
223
223
|
end
|
224
|
-
|
224
|
+
|
225
225
|
it "should not be >=" do
|
226
226
|
(@k1 >= @k2).should == false
|
227
227
|
end
|
data/spec/from_hash_spec.rb
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
require File.expand_path(File.dirname(__FILE__) + '/spec_helper')
|
2
2
|
|
3
3
|
describe "Kronos from_hash" do
|
4
|
-
|
4
|
+
|
5
5
|
it "2002" do
|
6
6
|
k = Kronos.from_hash({
|
7
7
|
'year' => 2002,
|
@@ -31,7 +31,7 @@ describe "Kronos from_hash" do
|
|
31
31
|
k.month.should == 11
|
32
32
|
k.day.should == 9
|
33
33
|
end
|
34
|
-
|
34
|
+
|
35
35
|
it "Malformed: ? 9, 2002" do
|
36
36
|
k = Kronos.from_hash({
|
37
37
|
'year' => 2002,
|
@@ -39,5 +39,6 @@ describe "Kronos from_hash" do
|
|
39
39
|
'day' => 9,
|
40
40
|
})
|
41
41
|
k.should == nil
|
42
|
-
end
|
43
|
-
|
42
|
+
end
|
43
|
+
|
44
|
+
end
|
data/spec/parse_spec.rb
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
require File.expand_path(File.dirname(__FILE__) + '/spec_helper')
|
2
2
|
|
3
3
|
describe "Kronos" do
|
4
|
-
|
4
|
+
|
5
5
|
it "15-Mar-2001" do
|
6
6
|
c = Kronos.parse("15-Mar-2001")
|
7
7
|
c.year.should == 2001
|
@@ -13,7 +13,7 @@ describe "Kronos" do
|
|
13
13
|
'day' => 15,
|
14
14
|
}
|
15
15
|
end
|
16
|
-
|
16
|
+
|
17
17
|
it "January 1976" do
|
18
18
|
c = Kronos.parse("January 1976")
|
19
19
|
c.year.should == 1976
|
@@ -84,7 +84,7 @@ describe "Kronos" do
|
|
84
84
|
'year' => 2019,
|
85
85
|
}
|
86
86
|
end
|
87
|
-
|
87
|
+
|
88
88
|
it "1/17/2007" do
|
89
89
|
c = Kronos.parse("1/17/2007")
|
90
90
|
c.year.should == 2007
|
@@ -96,7 +96,7 @@ describe "Kronos" do
|
|
96
96
|
'day' => 17,
|
97
97
|
}
|
98
98
|
end
|
99
|
-
|
99
|
+
|
100
100
|
it "Aug-96" do
|
101
101
|
c = Kronos.parse("Aug-96")
|
102
102
|
c.year.should == 1996
|
@@ -119,7 +119,7 @@ describe "Kronos" do
|
|
119
119
|
'day' => 15,
|
120
120
|
}
|
121
121
|
end
|
122
|
-
|
122
|
+
|
123
123
|
it "nil" do
|
124
124
|
c = Kronos.parse(nil)
|
125
125
|
c.year.should == nil
|
@@ -127,7 +127,7 @@ describe "Kronos" do
|
|
127
127
|
c.day.should == nil
|
128
128
|
c.to_hash.should == {}
|
129
129
|
end
|
130
|
-
|
130
|
+
|
131
131
|
it "empty string" do
|
132
132
|
c = Kronos.parse("")
|
133
133
|
c.year.should == nil
|
@@ -143,7 +143,7 @@ describe "Kronos" do
|
|
143
143
|
c.day.should == nil
|
144
144
|
c.to_hash.should == {}
|
145
145
|
end
|
146
|
-
|
146
|
+
|
147
147
|
it "prior to 1998" do
|
148
148
|
c = Kronos.parse("prior to 1998")
|
149
149
|
c.year.should == nil
|
@@ -151,5 +151,5 @@ describe "Kronos" do
|
|
151
151
|
c.day.should == nil
|
152
152
|
c.to_hash.should == {}
|
153
153
|
end
|
154
|
-
|
154
|
+
|
155
155
|
end
|
data/spec/spec_helper.rb
CHANGED
@@ -1,10 +1,8 @@
|
|
1
|
-
$LOAD_PATH.unshift(File.dirname(__FILE__))
|
2
|
-
$LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
|
3
1
|
require 'rubygems'
|
4
|
-
require '
|
5
|
-
require '
|
6
|
-
require '
|
2
|
+
require 'bundler/setup'
|
3
|
+
require 'rspec'
|
4
|
+
require File.expand_path('../../lib/kronos', __FILE__)
|
7
5
|
|
8
|
-
|
9
|
-
|
10
|
-
end
|
6
|
+
Rspec.configure do |c|
|
7
|
+
c.mock_with :rspec
|
8
|
+
end
|
data/spec/to_s_spec.rb
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
require File.expand_path(File.dirname(__FILE__) + '/spec_helper')
|
2
2
|
|
3
3
|
describe "to_s" do
|
4
|
-
|
4
|
+
|
5
5
|
def new_kronos(year=nil, month=nil, day=nil)
|
6
6
|
k = Kronos.new
|
7
7
|
k.year = year if year
|
@@ -9,7 +9,7 @@ describe "to_s" do
|
|
9
9
|
k.day = day if day
|
10
10
|
k
|
11
11
|
end
|
12
|
-
|
12
|
+
|
13
13
|
describe "2005" do
|
14
14
|
it "should be '2005'" do
|
15
15
|
k = new_kronos(2005)
|
data/spec/valid_spec.rb
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
require File.expand_path(File.dirname(__FILE__) + '/spec_helper')
|
2
2
|
|
3
3
|
describe "Kronos Comparisons" do
|
4
|
-
|
4
|
+
|
5
5
|
def new_kronos(year=nil, month=nil, day=nil)
|
6
6
|
k = Kronos.new
|
7
7
|
k.year = year if year
|
@@ -9,25 +9,49 @@ describe "Kronos Comparisons" do
|
|
9
9
|
k.day = day if day
|
10
10
|
k
|
11
11
|
end
|
12
|
-
|
12
|
+
|
13
13
|
it "year only is valid" do
|
14
|
-
new_kronos(2005).valid?.should
|
14
|
+
new_kronos(2005).valid?.should be_true
|
15
15
|
end
|
16
16
|
|
17
17
|
it "month and year is valid" do
|
18
|
-
new_kronos(2005, 8).valid?.should
|
18
|
+
new_kronos(2005, 8).valid?.should be_true
|
19
|
+
end
|
20
|
+
|
21
|
+
it "day and year is invalid" do
|
22
|
+
new_kronos(2005, nil, 22).valid?.should be_false
|
23
|
+
end
|
24
|
+
|
25
|
+
it "nothing is invalid" do
|
26
|
+
new_kronos(nil, nil, nil).valid?.should be_false
|
19
27
|
end
|
20
28
|
|
21
29
|
it "month, day, and year is valid" do
|
22
|
-
new_kronos(2005, 8, 22).valid?.should
|
30
|
+
new_kronos(2005, 8, 22).valid?.should be_true
|
23
31
|
end
|
24
32
|
|
25
|
-
it "day and year is invalid" do
|
26
|
-
new_kronos(2005,
|
33
|
+
it "month, day, and year with out-of-range month is invalid" do
|
34
|
+
new_kronos(2005, 13, 22).valid?.should be_false
|
27
35
|
end
|
28
|
-
|
29
|
-
it "
|
30
|
-
new_kronos(
|
36
|
+
|
37
|
+
it "month, day, and year with out-of-range day is invalid" do
|
38
|
+
new_kronos(2005, 4, 32).valid?.should be_false
|
39
|
+
end
|
40
|
+
|
41
|
+
it "June 0, 2005 is invalid" do
|
42
|
+
new_kronos(2005, 6, 0).valid?.should be_false
|
43
|
+
end
|
44
|
+
|
45
|
+
it "June 31, 2005 is invalid" do
|
46
|
+
new_kronos(2005, 6, 31).valid?.should be_false
|
47
|
+
end
|
48
|
+
|
49
|
+
it "February 29, 2008 is valid" do
|
50
|
+
new_kronos(2008, 2, 29).valid?.should be_true
|
51
|
+
end
|
52
|
+
|
53
|
+
it "February 29, 2010 is invalid" do
|
54
|
+
new_kronos(2010, 2, 29).valid?.should be_false
|
31
55
|
end
|
32
56
|
|
33
|
-
end
|
57
|
+
end
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: kronos
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 9
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 1
|
9
|
-
-
|
10
|
-
version: 0.1.
|
9
|
+
- 9
|
10
|
+
version: 0.1.9
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- David James
|
@@ -15,25 +15,69 @@ autorequire:
|
|
15
15
|
bindir: bin
|
16
16
|
cert_chain: []
|
17
17
|
|
18
|
-
date: 2010-10
|
18
|
+
date: 2010-12-10 00:00:00 -05:00
|
19
19
|
default_executable:
|
20
20
|
dependencies:
|
21
21
|
- !ruby/object:Gem::Dependency
|
22
|
-
|
22
|
+
type: :runtime
|
23
23
|
prerelease: false
|
24
|
-
|
24
|
+
name: kronos
|
25
|
+
version_requirements: &id001 !ruby/object:Gem::Requirement
|
25
26
|
none: false
|
26
27
|
requirements:
|
27
28
|
- - ">="
|
28
29
|
- !ruby/object:Gem::Version
|
29
|
-
hash:
|
30
|
+
hash: 3
|
31
|
+
segments:
|
32
|
+
- 0
|
33
|
+
version: "0"
|
34
|
+
requirement: *id001
|
35
|
+
- !ruby/object:Gem::Dependency
|
36
|
+
type: :development
|
37
|
+
prerelease: false
|
38
|
+
name: jeweler
|
39
|
+
version_requirements: &id002 !ruby/object:Gem::Requirement
|
40
|
+
none: false
|
41
|
+
requirements:
|
42
|
+
- - ~>
|
43
|
+
- !ruby/object:Gem::Version
|
44
|
+
hash: 1
|
30
45
|
segments:
|
31
46
|
- 1
|
47
|
+
- 5
|
48
|
+
- 1
|
49
|
+
version: 1.5.1
|
50
|
+
requirement: *id002
|
51
|
+
- !ruby/object:Gem::Dependency
|
52
|
+
type: :development
|
53
|
+
prerelease: false
|
54
|
+
name: rspec
|
55
|
+
version_requirements: &id003 !ruby/object:Gem::Requirement
|
56
|
+
none: false
|
57
|
+
requirements:
|
58
|
+
- - ~>
|
59
|
+
- !ruby/object:Gem::Version
|
60
|
+
hash: 7
|
61
|
+
segments:
|
62
|
+
- 2
|
32
63
|
- 2
|
33
|
-
|
34
|
-
|
64
|
+
version: "2.2"
|
65
|
+
requirement: *id003
|
66
|
+
- !ruby/object:Gem::Dependency
|
35
67
|
type: :development
|
36
|
-
|
68
|
+
prerelease: false
|
69
|
+
name: rspec
|
70
|
+
version_requirements: &id004 !ruby/object:Gem::Requirement
|
71
|
+
none: false
|
72
|
+
requirements:
|
73
|
+
- - ~>
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
hash: 7
|
76
|
+
segments:
|
77
|
+
- 2
|
78
|
+
- 2
|
79
|
+
version: "2.2"
|
80
|
+
requirement: *id004
|
37
81
|
description: Kronos provides flexible date parsing. Currently just a thin layer on top of ParseDate.
|
38
82
|
email: djames@sunlightfoundation.com
|
39
83
|
executables: []
|
@@ -44,14 +88,16 @@ extra_rdoc_files:
|
|
44
88
|
- LICENSE
|
45
89
|
- README.md
|
46
90
|
files:
|
91
|
+
- .bundle/config
|
47
92
|
- .document
|
48
|
-
-
|
93
|
+
- Gemfile
|
94
|
+
- Gemfile.lock
|
49
95
|
- LICENSE
|
50
96
|
- README.md
|
51
97
|
- Rakefile
|
52
|
-
- VERSION
|
53
98
|
- kronos.gemspec
|
54
99
|
- lib/kronos.rb
|
100
|
+
- lib/version.rb
|
55
101
|
- spec/compare_spec.rb
|
56
102
|
- spec/from_hash_spec.rb
|
57
103
|
- spec/parse_spec.rb
|
@@ -64,8 +110,8 @@ homepage: http://github.com/djsun/kronos
|
|
64
110
|
licenses: []
|
65
111
|
|
66
112
|
post_install_message:
|
67
|
-
rdoc_options:
|
68
|
-
|
113
|
+
rdoc_options: []
|
114
|
+
|
69
115
|
require_paths:
|
70
116
|
- lib
|
71
117
|
required_ruby_version: !ruby/object:Gem::Requirement
|
@@ -88,7 +134,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
88
134
|
version: "0"
|
89
135
|
requirements: []
|
90
136
|
|
91
|
-
rubyforge_project:
|
137
|
+
rubyforge_project: kronos
|
92
138
|
rubygems_version: 1.3.7
|
93
139
|
signing_key:
|
94
140
|
specification_version: 3
|
data/.gitignore
DELETED
data/VERSION
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
0.1.8
|