date_time-smart 0.0.2 → 0.0.3
Sign up to get free protection for your applications and to get access to all the features.
- data/ChangeLog +4 -0
- data/Rakefile +1 -1
- data/lib/date_time/smart.rb +6 -3
- metadata +1 -1
data/ChangeLog
CHANGED
data/Rakefile
CHANGED
@@ -19,7 +19,7 @@ RUBYFORGE_PROJECT_ID = 4314
|
|
19
19
|
RUBYFORGE_PACKAGE_ID = 6502
|
20
20
|
HOMEPATH = "http://#{RUBYFORGE_PROJECT}.rubyforge.org"
|
21
21
|
BIN_FILES = %w( )
|
22
|
-
VERS = "0.0.
|
22
|
+
VERS = "0.0.3"
|
23
23
|
|
24
24
|
REV = File.read(".svn/entries")[/committed-rev="(d+)"/, 1] rescue nil
|
25
25
|
CLEAN.include ['**/.*.sw?', '*.gem', '.config']
|
data/lib/date_time/smart.rb
CHANGED
@@ -41,7 +41,7 @@ class DateTime
|
|
41
41
|
end
|
42
42
|
|
43
43
|
def inspect
|
44
|
-
"#<#{self.class}: #{self.to_s}, #{self.ajd}, #{self.offset}, #{self.
|
44
|
+
"#<#{self.class}: #{self.to_s}, #{self.ajd}, #{self.offset}, #{self.start}>"
|
45
45
|
end
|
46
46
|
end
|
47
47
|
|
@@ -49,18 +49,21 @@ class DateTime
|
|
49
49
|
def now(sg = Date::ITALY)
|
50
50
|
dt = DateTime.now(sg)
|
51
51
|
|
52
|
-
new!(dt.ajd, dt.offset, dt.
|
52
|
+
new!(dt.ajd, dt.offset, dt.start)
|
53
53
|
end
|
54
54
|
|
55
55
|
def today(sg = Date::ITALY)
|
56
56
|
dt = Date.today(sg)
|
57
57
|
|
58
|
-
new!(dt.ajd, dt.offset, dt.
|
58
|
+
new!(dt.ajd, dt.__send__(:offset), dt.start)
|
59
59
|
end
|
60
60
|
end
|
61
61
|
|
62
62
|
alias original_add +
|
63
63
|
alias original_subtract -
|
64
|
+
|
65
|
+
public :offset
|
66
|
+
|
64
67
|
include Shared
|
65
68
|
extend SharedClassMethods
|
66
69
|
end
|
metadata
CHANGED