tempus 1.0.0 → 1.0.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: cb484b5639a9056346df03f032edb5a4b760cb8f95038e63a14b8addfb4e3870
4
- data.tar.gz: fd6fb864680e411abec1319a1a29d275a73471ffacecfd6fa2e0287d0c8b6f1e
3
+ metadata.gz: 2001b2e89f2be1909675a61ef595fcb3fa103b575c90cdcf1186961bac14077e
4
+ data.tar.gz: 3952d416260d86f7ef8c2fadc77077e6c27f937462625bcca5b177e09dd01499
5
5
  SHA512:
6
- metadata.gz: 8c9eb435c0b25fc7a19e65976b5c174e9ac50491dbcbffda56bcb648177f13ed686d5b384891e0cfb7e68d04f4d747dd8cc66a8705580d02ab93f988c6730f6b
7
- data.tar.gz: 9f7fc113198a35d68619263fc42735a79d5fe7818693bc942dbb70fef577b6541aaa8530ab3f7385edb1cb89c8071e995e01e707758a1c6787ebd27999082eb1
6
+ metadata.gz: fed0de79e4abb9a77b68606052c5011a16dd5dadf7abf4782b61ac225dbdbddca39b8d39f22d139c515c48013a617b160012e89eaba9f3f8a95e75848e89cde3
7
+ data.tar.gz: 5d4f7b6952b668b061ffb83451f721d97809810089b0b4c0748060a2cdde89c7729e0badc2d31ab0eb7ed6b4088cbcda0a9a80dde56baec837bffb17289d8627
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- tempus (1.0.0)
4
+ tempus (1.0.1)
5
5
  activesupport (> 5)
6
6
 
7
7
  GEM
data/lib/tempus.rb CHANGED
@@ -17,7 +17,7 @@ class Tempus
17
17
  MINUTES_REGEX = /(\%m|\%mm|\%M|\%MM)/.freeze
18
18
  SECONDS_REGEX = /(\%s|\%ss|\%S|\%SS)/.freeze
19
19
 
20
- attr_accessor :data
20
+ attr_reader :data
21
21
 
22
22
  delegate :to_i, :to_f, :negative?, :positive?, to: :data
23
23
 
@@ -121,6 +121,16 @@ class Tempus
121
121
  Tempus.new(data - transform(other))
122
122
  end
123
123
 
124
+ # Multiplication values of instance
125
+ def *(other)
126
+ Tempus.new(data * transform(other))
127
+ end
128
+
129
+ # Division values of instance
130
+ def /(other)
131
+ Tempus.new(data / transform(other))
132
+ end
133
+
124
134
  def human
125
135
  [
126
136
  ('menos' if negative?),
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  class Tempus
4
- VERSION = '1.0.0'
4
+ VERSION = '1.0.1'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tempus
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Danilo Jeremias da Silva
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2019-08-22 00:00:00.000000000 Z
11
+ date: 2019-10-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -141,7 +141,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
141
141
  - !ruby/object:Gem::Version
142
142
  version: '0'
143
143
  requirements: []
144
- rubygems_version: 3.0.4
144
+ rubygems_version: 3.0.6
145
145
  signing_key:
146
146
  specification_version: 4
147
147
  summary: Gem to efficiently manipulate the time.