reasonable-value 0.2.6 → 0.2.7
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.
- checksums.yaml +4 -4
- data/.rubocop.yml +44 -45
- data/lib/reasonable/value.rb +1 -1
- data/lib/reasonable/value/version.rb +1 -1
- data/reasonable-value.gemspec +1 -0
- metadata +16 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 1a6ba63d824314b0161436aa7b77918447bd1983
|
|
4
|
+
data.tar.gz: 2fcca18d5fb181b9e8dff39adc203e7a5072d7fd
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 38d6f2e5a3eb2ce6aa2d322d67fda60a53ac37694ece55b7635ec9196a283be12c24133d8a1d7a0de7cb12f10410a0dfc39562ce3325e200fc0e1b39ff718972
|
|
7
|
+
data.tar.gz: 49c8d43a35dcc3d175f46eef5883cc6ed07d1a505371bac543faa5569c5993adbd46d058115b22860d38ee837299baa6889e0517b426d01506747606c4959e5a
|
data/.rubocop.yml
CHANGED
|
@@ -1,13 +1,52 @@
|
|
|
1
1
|
AllCops:
|
|
2
|
-
|
|
3
|
-
TargetRubyVersion: 2.3
|
|
4
|
-
|
|
5
|
-
Style/DotPosition:
|
|
6
|
-
EnforcedStyle: trailing
|
|
2
|
+
TargetRubyVersion: 2.4
|
|
7
3
|
|
|
8
4
|
ClassLength:
|
|
9
5
|
Max: 150
|
|
10
6
|
|
|
7
|
+
Layout/DotPosition:
|
|
8
|
+
EnforcedStyle: trailing
|
|
9
|
+
|
|
10
|
+
Layout/AlignParameters:
|
|
11
|
+
EnforcedStyle: with_first_parameter
|
|
12
|
+
|
|
13
|
+
Layout/EmptyLines:
|
|
14
|
+
Description: "Don't use several empty lines in a row."
|
|
15
|
+
Enabled: true
|
|
16
|
+
|
|
17
|
+
Layout/EmptyLinesAroundBlockBody:
|
|
18
|
+
Description: "Keeps track of empty lines around block bodies."
|
|
19
|
+
Enabled: false
|
|
20
|
+
|
|
21
|
+
Layout/EmptyLinesAroundClassBody:
|
|
22
|
+
EnforcedStyle: empty_lines
|
|
23
|
+
SupportedStyles:
|
|
24
|
+
- empty_lines
|
|
25
|
+
- no_empty_lines
|
|
26
|
+
|
|
27
|
+
Layout/EmptyLinesAroundModuleBody:
|
|
28
|
+
EnforcedStyle: no_empty_lines
|
|
29
|
+
SupportedStyles:
|
|
30
|
+
- empty_lines
|
|
31
|
+
- no_empty_lines
|
|
32
|
+
|
|
33
|
+
Layout/EndOfLine:
|
|
34
|
+
Description: 'Use Unix-style line endings.'
|
|
35
|
+
StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#crlf'
|
|
36
|
+
Enabled: true
|
|
37
|
+
|
|
38
|
+
Layout/ExtraSpacing:
|
|
39
|
+
# When true, allows most uses of extra spacing if the intent is to align
|
|
40
|
+
# things with the previous or next line, not counting empty lines or comment
|
|
41
|
+
# lines.
|
|
42
|
+
AllowForAlignment: true
|
|
43
|
+
|
|
44
|
+
Layout/MultilineOperationIndentation:
|
|
45
|
+
EnforcedStyle: indented
|
|
46
|
+
|
|
47
|
+
Layout/MultilineMethodCallIndentation:
|
|
48
|
+
EnforcedStyle: indented
|
|
49
|
+
|
|
11
50
|
Metrics/LineLength:
|
|
12
51
|
Max: 100
|
|
13
52
|
|
|
@@ -26,18 +65,9 @@ Metrics/BlockLength:
|
|
|
26
65
|
Style/AndOr:
|
|
27
66
|
Enabled: false
|
|
28
67
|
|
|
29
|
-
Style/AlignParameters:
|
|
30
|
-
EnforcedStyle: with_first_parameter
|
|
31
|
-
|
|
32
68
|
Style/Documentation:
|
|
33
69
|
Enabled: false
|
|
34
70
|
|
|
35
|
-
Style/ExtraSpacing:
|
|
36
|
-
# When true, allows most uses of extra spacing if the intent is to align
|
|
37
|
-
# things with the previous or next line, not counting empty lines or comment
|
|
38
|
-
# lines.
|
|
39
|
-
AllowForAlignment: true
|
|
40
|
-
|
|
41
71
|
Style/LambdaCall:
|
|
42
72
|
Enabled: true
|
|
43
73
|
EnforcedStyle: braces
|
|
@@ -45,40 +75,9 @@ Style/LambdaCall:
|
|
|
45
75
|
Style/StringLiterals:
|
|
46
76
|
EnforcedStyle: single_quotes
|
|
47
77
|
|
|
48
|
-
Style/EmptyLinesAroundClassBody:
|
|
49
|
-
EnforcedStyle: empty_lines
|
|
50
|
-
SupportedStyles:
|
|
51
|
-
- empty_lines
|
|
52
|
-
- no_empty_lines
|
|
53
|
-
|
|
54
|
-
Style/EmptyLinesAroundModuleBody:
|
|
55
|
-
EnforcedStyle: no_empty_lines
|
|
56
|
-
SupportedStyles:
|
|
57
|
-
- empty_lines
|
|
58
|
-
- no_empty_lines
|
|
59
|
-
|
|
60
|
-
Style/EmptyLinesAroundBlockBody:
|
|
61
|
-
Description: "Keeps track of empty lines around block bodies."
|
|
62
|
-
Enabled: false
|
|
63
|
-
|
|
64
|
-
Style/EmptyLines:
|
|
65
|
-
Description: "Don't use several empty lines in a row."
|
|
66
|
-
Enabled: true
|
|
67
|
-
|
|
68
78
|
Style/EmptyCaseCondition:
|
|
69
79
|
Enabled: false
|
|
70
80
|
|
|
71
|
-
Style/EndOfLine:
|
|
72
|
-
Description: 'Use Unix-style line endings.'
|
|
73
|
-
StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#crlf'
|
|
74
|
-
Enabled: true
|
|
75
|
-
|
|
76
|
-
Style/MultilineOperationIndentation:
|
|
77
|
-
EnforcedStyle: indented
|
|
78
|
-
|
|
79
|
-
Style/MultilineMethodCallIndentation:
|
|
80
|
-
EnforcedStyle: indented
|
|
81
|
-
|
|
82
81
|
Style/WordArray:
|
|
83
82
|
Description: 'Use %w or %W for arrays of words.'
|
|
84
83
|
StyleGuide: 'https://github.com/bbatsov/ruby-style-guide#percent-w'
|
data/lib/reasonable/value.rb
CHANGED
|
@@ -17,7 +17,7 @@ module Reasonable
|
|
|
17
17
|
self.class.send(:config).each do |name, config|
|
|
18
18
|
options = config[:options]
|
|
19
19
|
if options[:optional]
|
|
20
|
-
attributes[name]
|
|
20
|
+
attributes[name] = options[:default] if attributes[name].nil?
|
|
21
21
|
next if attributes[name].nil?
|
|
22
22
|
end
|
|
23
23
|
|
data/reasonable-value.gemspec
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: reasonable-value
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.2.
|
|
4
|
+
version: 0.2.7
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Thomas Larrieu
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date:
|
|
11
|
+
date: 2018-09-26 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: activesupport
|
|
@@ -66,6 +66,20 @@ dependencies:
|
|
|
66
66
|
- - "~>"
|
|
67
67
|
- !ruby/object:Gem::Version
|
|
68
68
|
version: '3.0'
|
|
69
|
+
- !ruby/object:Gem::Dependency
|
|
70
|
+
name: rubocop
|
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
|
72
|
+
requirements:
|
|
73
|
+
- - "~>"
|
|
74
|
+
- !ruby/object:Gem::Version
|
|
75
|
+
version: 0.59.2
|
|
76
|
+
type: :development
|
|
77
|
+
prerelease: false
|
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
79
|
+
requirements:
|
|
80
|
+
- - "~>"
|
|
81
|
+
- !ruby/object:Gem::Version
|
|
82
|
+
version: 0.59.2
|
|
69
83
|
description:
|
|
70
84
|
email:
|
|
71
85
|
- thomas.larrieu@gmail.com
|