lite-measurements 1.0.1 → 1.0.2

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: 754758e082964cbd6e746fa1600d70407cb166a6f734f030dfa7af4c6f56ab59
4
- data.tar.gz: 5ca5b154d0e48b2548d36f4f7e9ae9a48ed55cf12f9916129d1c15ed4595ad66
3
+ metadata.gz: 9259cdb3e90321e0acf11ffdbc87deea1dd586e9cfb530de8250c94ae7751fa1
4
+ data.tar.gz: fea4f5aab97984d830feecb62a2d0106d84d9222f11f5c2930ef7b68c1189723
5
5
  SHA512:
6
- metadata.gz: d8c81eff5ded61aa3674bf11d31d1c06e06d3044866bdeb04b2e62896c2a6ee0336884c1843e0dfa46ab06c87cacd893bf8a88d7f39cf3ae5cd3a1e16f119346
7
- data.tar.gz: 8caa230d94af106122f5d281b52f53051d737eacfe5c6618da6d55c04c5741b4cd01612326a7be697795ebea92d4c92e71a629d8d91511b675a4509ba64237cb
6
+ metadata.gz: 4bad2ee185da401aa15165fd9e7c43f09f70d6d72a3ee72e193ab6e6680eca48a0946a1ae0ef90908a3c8ba63ef68d0f2ffefd2451f839dc2e22d2107959fa92
7
+ data.tar.gz: d70e6d4f2381c2389c54a052e2dc6efa98473eb5254d524d155e3d46e54563d4496e1a4f29ffc991cf16109ac954c0bdb7da3839ed06ad0d01f6cc5f5cbcaf49
data/CHANGELOG.md CHANGED
@@ -6,6 +6,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
6
6
 
7
7
  ## [Unreleased]
8
8
 
9
+ ## [1.0.2] - 2019-08-24
10
+ ### Changed
11
+ - Imporved how configuration works
12
+
9
13
  ## [1.0.1] - 2019-08-17
10
14
  ### Changed
11
15
  - Add check for monkey patches
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- lite-measurements (1.0.1)
4
+ lite-measurements (1.0.2)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
@@ -2,16 +2,13 @@
2
2
 
3
3
  require 'lite/measurements/version'
4
4
  require 'lite/measurements/configuration'
5
- require 'lite/measurements/helpers/conversion_helper'
6
5
 
7
6
  %w[conversion shift].each do |filename|
8
7
  require "lite/measurements/helpers/#{filename}_helper"
9
8
  end
10
9
 
11
- %w[base digital_storage length mass temperature time].each do |filename|
10
+ %w[base digital_storage length mass temperature time monkey_patches].each do |filename|
12
11
  require "lite/measurements/#{filename}"
13
12
  end
14
13
 
15
- require 'lite/measurements/monkey_patches' if Lite::Measurements.configuration.monkey_patches
16
-
17
14
  require 'generators/lite/measurements/install_generator'
@@ -13,16 +13,22 @@ module Lite
13
13
 
14
14
  end
15
15
 
16
- def self.configuration
17
- @configuration ||= Configuration.new
18
- end
16
+ class << self
19
17
 
20
- def self.configuration=(config)
21
- @configuration = config
22
- end
18
+ attr_writer :configuration
19
+
20
+ def configuration
21
+ @configuration ||= Configuration.new
22
+ end
23
+
24
+ def configure
25
+ yield(configuration)
26
+ end
27
+
28
+ def reset_configuration!
29
+ @configuration = Configuration.new
30
+ end
23
31
 
24
- def self.configure
25
- yield(configuration)
26
32
  end
27
33
 
28
34
  end
@@ -3,7 +3,7 @@
3
3
  module Lite
4
4
  module Measurements
5
5
 
6
- VERSION ||= '1.0.1'
6
+ VERSION ||= '1.0.2'
7
7
 
8
8
  end
9
9
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lite-measurements
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.1
4
+ version: 1.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Juan Gomez
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2019-08-17 00:00:00.000000000 Z
11
+ date: 2019-08-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler