sleeping_king_studios-tools 0.1.3 → 0.2.0.beta.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +6 -0
- data/README.md +82 -10
- data/lib/sleeping_king_studios/tools/array_tools.rb +111 -0
- data/lib/sleeping_king_studios/tools/enumerable_tools.rb +3 -95
- data/lib/sleeping_king_studios/tools/hash_tools.rb +23 -0
- data/lib/sleeping_king_studios/tools/object_tools.rb +24 -0
- data/lib/sleeping_king_studios/tools/semantic_version.rb +2 -3
- data/lib/sleeping_king_studios/tools/version.rb +6 -2
- metadata +32 -21
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6e8dad1b2f806deaa242881f79db4d56f4058dfb
|
4
|
+
data.tar.gz: 3ff535315372519db5ab455483baec4499e401e4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0a168b831645d542efbdafa26cb99a751047a887a49bf3b1b09dc9947aea0883c7fe097577222295c15c8ed7aece5563e50cc906404ef9333f4bb98226a48b9b
|
7
|
+
data.tar.gz: 4534a229197c7d499f7ef958f25a33b7a89b0450d219240ad0d78ead2892f0c5c12502bab509db2fdd98beb7f4ad4b11fa5d5e091ceb05c017d1fe73b77c1aff
|
data/CHANGELOG.md
CHANGED
@@ -2,6 +2,12 @@
|
|
2
2
|
|
3
3
|
## Pre-release Versions
|
4
4
|
|
5
|
+
### 0.2.0
|
6
|
+
|
7
|
+
Split EnumerableTools into ArrayTools and HashTools.
|
8
|
+
|
9
|
+
Implement ArrayTools#deep_dup, HashTools#deep_dup and ObjectTools#deep_dup.
|
10
|
+
|
5
11
|
### 0.1.3
|
6
12
|
|
7
13
|
Properly support both keywords and optional arguments in ObjectTools#apply.
|
data/README.md
CHANGED
@@ -12,41 +12,79 @@ Hi, I'm Rob Smith, a Ruby Engineer and the developer of this library. I use thes
|
|
12
12
|
|
13
13
|
## Tools
|
14
14
|
|
15
|
-
###
|
15
|
+
### Array Tools
|
16
16
|
|
17
|
-
require 'sleeping_king_studios/tools/
|
17
|
+
require 'sleeping_king_studios/tools/array_tools'
|
18
18
|
|
19
|
-
Tools for working with enumerable objects
|
19
|
+
Tools for working with array-like enumerable objects.
|
20
20
|
|
21
21
|
#### `#count_values`
|
22
22
|
|
23
|
-
Counts the number of times each value appears in the
|
23
|
+
Counts the number of times each value appears in the array, or if a block is given, calls the block with each item and counts the number of times each result appears.
|
24
24
|
|
25
|
-
|
25
|
+
ArrayTools.count_values([1, 1, 1, 2, 2, 3])
|
26
26
|
#=> { 1 => 3, 2 => 2, 3 => 1 }
|
27
27
|
|
28
|
-
|
28
|
+
ArrayTools.count_values([1, 1, 1, 2, 2, 3]) { |i| i ** 2 }
|
29
29
|
#=> { 1 => 3, 4 => 2, 9 => 1 }
|
30
30
|
|
31
|
-
|
31
|
+
ArrayTools.count_values([1, 1, 1, 2, 2, 3], &:even?)
|
32
32
|
#=> { false => 4, true => 2 }
|
33
33
|
|
34
|
+
#### `#deep_dup`
|
35
|
+
|
36
|
+
Creates a deep copy of the object by returning a new Array with deep copies of each array item. See also ObjectTools#deep_dup[#label-Object+Tools].
|
37
|
+
|
38
|
+
ary = ['one', 'two', 'three']
|
39
|
+
cpy = ArrayTools.deep_dup ary
|
40
|
+
|
41
|
+
cpy << 'four'
|
42
|
+
#=> ['one', 'two', 'three', 'four']
|
43
|
+
ary
|
44
|
+
#=> ['one', 'two', 'three']
|
45
|
+
|
46
|
+
cpy.first.sub!(/on/, 'vu'); cpy
|
47
|
+
#=> ['vun', 'two', 'three', 'four']
|
48
|
+
ary
|
49
|
+
#=> ['one', 'two', 'three']
|
50
|
+
|
34
51
|
#### `#humanize_list`
|
35
52
|
|
36
53
|
Accepts a list of values and returns a human-readable string of the values, with the format based on the number of items.
|
37
54
|
|
38
55
|
# With One Item
|
39
|
-
|
56
|
+
ArrayTools.humanize_list(['spam'])
|
40
57
|
#=> 'spam'
|
41
58
|
|
42
59
|
# With Two Items
|
43
|
-
|
60
|
+
ArrayTools.humanize_list(['spam', 'eggs'])
|
44
61
|
#=> 'spam and eggs'
|
45
62
|
|
46
63
|
# With Three Or More Items
|
47
|
-
|
64
|
+
ArrayTools.humanize_list(['spam', 'eggs', 'bacon', 'spam'])
|
48
65
|
#=> 'spam, eggs, bacon, and spam'
|
49
66
|
|
67
|
+
### Hash Tools
|
68
|
+
|
69
|
+
Tools for working with array-like enumerable objects.
|
70
|
+
|
71
|
+
#### `#deep_dup`
|
72
|
+
|
73
|
+
Creates a deep copy of the object by returning a new Hash with deep copies of each key and value. See also ObjectTools#deep_dup[#label-Object+Tools].
|
74
|
+
|
75
|
+
hsh = { :one => 'one', :two => 'two', :three => 'three' }
|
76
|
+
cpy = HashTools.deep_dup hsh
|
77
|
+
|
78
|
+
cpy.update :four => 'four'
|
79
|
+
#=> { :one => 'one', :two => 'two', :three => 'three', :four => 'four' }
|
80
|
+
hsh
|
81
|
+
#=> { :one => 'one', :two => 'two', :three => 'three' }
|
82
|
+
|
83
|
+
cpy[:one].sub!(/on/, 'vu'); cpy
|
84
|
+
#=> { :one => 'vun', :two => 'two', :three => 'three', :four => 'four' }
|
85
|
+
hsh
|
86
|
+
#=> { :one => 'one', :two => 'two', :three => 'three' }
|
87
|
+
|
50
88
|
### Integer Tools
|
51
89
|
|
52
90
|
Tools for working with integers and fixnums.
|
@@ -110,6 +148,40 @@ Takes a proc or lambda and invokes it with the given object as receiver, with an
|
|
110
148
|
ObjectTools.apply my_object, my_proc
|
111
149
|
#=> Writes 'A mock object says "Greetings, programs!"' to STDOUT.
|
112
150
|
|
151
|
+
#### `#deep_dup`
|
152
|
+
|
153
|
+
Creates a deep copy of the object. If the object is an Array, returns a new Array with deep copies of each array item (see ArrayTools#deep_dup[#label-Array+Tools]). If the object is a Hash, returns a new Hash with deep copies of each hash key and value (see HashTools#deep_dup[#label-Hash+Tools]). Otherwise, returns Object#dup.
|
154
|
+
|
155
|
+
data = {
|
156
|
+
:songs = [
|
157
|
+
{
|
158
|
+
:name => 'Welcome to the Jungle',
|
159
|
+
:artist => "Guns N' Roses",
|
160
|
+
:album => 'Appetite for Destruction'
|
161
|
+
}, # end hash
|
162
|
+
{
|
163
|
+
:name => 'Hells Bells',
|
164
|
+
:artist => 'AC/DC',
|
165
|
+
:album => 'Back in Black'
|
166
|
+
}, # end hash
|
167
|
+
{
|
168
|
+
:name => "Knockin' on Heaven's Door",
|
169
|
+
:artist => 'Bob Dylan',
|
170
|
+
:album => 'Pat Garrett & Billy The Kid'
|
171
|
+
} # end hash
|
172
|
+
] # end array
|
173
|
+
} # end hash
|
174
|
+
|
175
|
+
copy = ObjectTools.deep_dup data
|
176
|
+
|
177
|
+
copy[:songs] << { :name => 'Sympathy for the Devil', :artist => 'The Rolling Stones', :album => 'Beggars Banquet' }
|
178
|
+
data[:songs].count
|
179
|
+
#=> 3
|
180
|
+
|
181
|
+
copy[:songs][1][:name] = 'Shoot to Thrill'
|
182
|
+
data[:songs][1]
|
183
|
+
#=> { :name => 'Hells Bells', :artist => 'AC/DC', :album => 'Back in Black' }
|
184
|
+
|
113
185
|
#### `#eigenclass`, `#metaclass`
|
114
186
|
|
115
187
|
Returns the object's eigenclass.
|
@@ -0,0 +1,111 @@
|
|
1
|
+
# lib/sleeping_king_studios/tools/array_tools.rb
|
2
|
+
|
3
|
+
require 'sleeping_king_studios/tools'
|
4
|
+
require 'sleeping_king_studios/tools/object_tools'
|
5
|
+
|
6
|
+
module SleepingKingStudios::Tools
|
7
|
+
# Tools for working with array-like enumerable objects.
|
8
|
+
module ArrayTools
|
9
|
+
extend self
|
10
|
+
|
11
|
+
# @overload count_values(values)
|
12
|
+
# Counts the number of times each value appears in the enumerable object.
|
13
|
+
#
|
14
|
+
# @example
|
15
|
+
# ArrayTools.count_values([1, 1, 1, 2, 2, 3])
|
16
|
+
# #=> { 1 => 3, 2 => 2, 3 => 1 }
|
17
|
+
#
|
18
|
+
# @param [Array<Object>] values The values to count.
|
19
|
+
#
|
20
|
+
# @return [Hash{Object, Integer}] The number of times each value appears
|
21
|
+
# in the enumerable object.
|
22
|
+
#
|
23
|
+
# @overload count_values(values, &block)
|
24
|
+
# Calls the block with each item and counts the number of times each
|
25
|
+
# result appears.
|
26
|
+
#
|
27
|
+
# @example
|
28
|
+
# ArrayTools.count_values([1, 1, 1, 2, 2, 3]) { |i| i ** 2 }
|
29
|
+
# #=> { 1 => 3, 4 => 2, 9 => 1 }
|
30
|
+
#
|
31
|
+
# @param [Array<Object>] values The values to count.
|
32
|
+
#
|
33
|
+
# @return [Hash{Object, Integer}] The number of times each result
|
34
|
+
# appears.
|
35
|
+
#
|
36
|
+
# @yield item An item in the array to be converted to a countable result.
|
37
|
+
def count_values values, &block
|
38
|
+
values.each.with_object({}) do |item, hsh|
|
39
|
+
value = block_given? ? block.call(item) : item
|
40
|
+
hsh[value] = hsh.fetch(value, 0) + 1
|
41
|
+
end # each
|
42
|
+
end # method count_values
|
43
|
+
|
44
|
+
# Creates a deep copy of the object by returning a new Array with deep
|
45
|
+
# copies of each array item.
|
46
|
+
#
|
47
|
+
# @param [Array<Object>] ary The array to copy.
|
48
|
+
#
|
49
|
+
# @return [Array] The copy of the array.
|
50
|
+
def deep_dup ary
|
51
|
+
ary.map { |obj| ObjectTools.deep_dup obj }
|
52
|
+
end # method deep_dup
|
53
|
+
|
54
|
+
# Accepts a list of values and returns a human-readable string of the
|
55
|
+
# values, with the format based on the number of items.
|
56
|
+
#
|
57
|
+
# @example With Zero Items
|
58
|
+
# ArrayTools.humanize_list([])
|
59
|
+
# #=> ''
|
60
|
+
#
|
61
|
+
# @example With One Item
|
62
|
+
# ArrayTools.humanize_list(['spam'])
|
63
|
+
# #=> 'spam'
|
64
|
+
#
|
65
|
+
# @example With Two Items
|
66
|
+
# ArrayTools.humanize_list(['spam', 'eggs'])
|
67
|
+
# #=> 'spam and eggs'
|
68
|
+
#
|
69
|
+
# @example With Three Or More Items
|
70
|
+
# ArrayTools.humanize_list(['spam', 'eggs', 'bacon', 'spam'])
|
71
|
+
# #=> 'spam, eggs, bacon, and spam'
|
72
|
+
#
|
73
|
+
# @example With Three Or More Items And Options
|
74
|
+
# ArrayTools.humanize_list(['spam', 'eggs', 'bacon', 'spam'], :last_separator => ' or ')
|
75
|
+
# #=> 'spam, eggs, bacon, or spam'
|
76
|
+
#
|
77
|
+
# @param [Array<String>] values The list of values to format. Will be
|
78
|
+
# coerced to strings using #to_s.
|
79
|
+
# @param [Hash] options Optional configuration hash.
|
80
|
+
# @option options [String] :last_separator The value to use to separate
|
81
|
+
# the final pair of values. Defaults to " and " (note the leading and
|
82
|
+
# trailing spaces). Will be combined with the :separator for lists of
|
83
|
+
# length 3 or greater.
|
84
|
+
# @option options [String] :separator The value to use to separate pairs
|
85
|
+
# of values before the last in lists of length 3 or greater. Defaults to
|
86
|
+
# ", " (note the trailing space).
|
87
|
+
#
|
88
|
+
# @return [String] The formatted string.
|
89
|
+
def humanize_list values, options = {}
|
90
|
+
separator = options.fetch(:separator, ', ')
|
91
|
+
last_separator = options.fetch(:last_separator, ' and ')
|
92
|
+
|
93
|
+
case values.count
|
94
|
+
when 0
|
95
|
+
''
|
96
|
+
when 1
|
97
|
+
values.first.to_s
|
98
|
+
when 2
|
99
|
+
"#{values[0]}#{last_separator}#{values[1]}"
|
100
|
+
else
|
101
|
+
if last_separator =~ /\A,?\s*/
|
102
|
+
last_separator = last_separator.sub /\A,?\s*/, separator
|
103
|
+
else
|
104
|
+
last_separator = "#{separator}#{last_separator}"
|
105
|
+
end # if-else
|
106
|
+
|
107
|
+
"#{values[0...-1].join(separator)}#{last_separator}#{values.last}"
|
108
|
+
end # case
|
109
|
+
end # method humanize_list
|
110
|
+
end # module
|
111
|
+
end # module
|
@@ -1,100 +1,8 @@
|
|
1
1
|
# lib/sleeping_king_studios/tools/enumerable_tools.rb
|
2
2
|
|
3
|
-
require 'sleeping_king_studios/tools'
|
3
|
+
require 'sleeping_king_studios/tools/array_tools'
|
4
4
|
|
5
5
|
module SleepingKingStudios::Tools
|
6
|
-
#
|
7
|
-
|
8
|
-
extend self
|
9
|
-
|
10
|
-
# @overload count_values(values)
|
11
|
-
# Counts the number of times each value appears in the enumerable object.
|
12
|
-
#
|
13
|
-
# @example
|
14
|
-
# ArrayTools.count_values([1, 1, 1, 2, 2, 3])
|
15
|
-
# #=> { 1 => 3, 2 => 2, 3 => 1 }
|
16
|
-
#
|
17
|
-
# @param [Array<Object>] values The values to count.
|
18
|
-
#
|
19
|
-
# @return [Hash{Object, Integer}] The number of times each value appears
|
20
|
-
# in the enumerable object.
|
21
|
-
#
|
22
|
-
# @overload count_values(values, &block)
|
23
|
-
# Calls the block with each item and counts the number of times each
|
24
|
-
# result appears.
|
25
|
-
#
|
26
|
-
# @example
|
27
|
-
# ArrayTools.count_values([1, 1, 1, 2, 2, 3]) { |i| i ** 2 }
|
28
|
-
# #=> { 1 => 3, 4 => 2, 9 => 1 }
|
29
|
-
#
|
30
|
-
# @param [Array<Object>] values The values to count.
|
31
|
-
#
|
32
|
-
# @return [Hash{Object, Integer}] The number of times each result
|
33
|
-
# appears.
|
34
|
-
#
|
35
|
-
# @yield item An item in the array to be converted to a countable result.
|
36
|
-
def count_values values, &block
|
37
|
-
values.each.with_object({}) do |item, hsh|
|
38
|
-
value = block_given? ? block.call(item) : item
|
39
|
-
hsh[value] = hsh.fetch(value, 0) + 1
|
40
|
-
end # each
|
41
|
-
end # method count_values
|
42
|
-
|
43
|
-
# Accepts a list of values and returns a human-readable string of the
|
44
|
-
# values, with the format based on the number of items.
|
45
|
-
#
|
46
|
-
# @example With Zero Items
|
47
|
-
# ArrayTools.humanize_list([])
|
48
|
-
# #=> ''
|
49
|
-
#
|
50
|
-
# @example With One Item
|
51
|
-
# ArrayTools.humanize_list(['spam'])
|
52
|
-
# #=> 'spam'
|
53
|
-
#
|
54
|
-
# @example With Two Items
|
55
|
-
# ArrayTools.humanize_list(['spam', 'eggs'])
|
56
|
-
# #=> 'spam and eggs'
|
57
|
-
#
|
58
|
-
# @example With Three Or More Items
|
59
|
-
# ArrayTools.humanize_list(['spam', 'eggs', 'bacon', 'spam'])
|
60
|
-
# #=> 'spam, eggs, bacon, and spam'
|
61
|
-
#
|
62
|
-
# @example With Three Or More Items And Options
|
63
|
-
# ArrayTools.humanize_list(['spam', 'eggs', 'bacon', 'spam'], :last_separator => ' or ')
|
64
|
-
# #=> 'spam, eggs, bacon, or spam'
|
65
|
-
#
|
66
|
-
# @param [Array<String>] values The list of values to format. Will be
|
67
|
-
# coerced to strings using #to_s.
|
68
|
-
# @param [Hash] options Optional configuration hash.
|
69
|
-
# @option options [String] :last_separator The value to use to separate
|
70
|
-
# the final pair of values. Defaults to " and " (note the leading and
|
71
|
-
# trailing spaces). Will be combined with the :separator for lists of
|
72
|
-
# length 3 or greater.
|
73
|
-
# @option options [String] :separator The value to use to separate pairs
|
74
|
-
# of values before the last in lists of length 3 or greater. Defaults to
|
75
|
-
# ", " (note the trailing space).
|
76
|
-
#
|
77
|
-
# @return [String] The formatted string.
|
78
|
-
def humanize_list values, options = {}
|
79
|
-
separator = options.fetch(:separator, ', ')
|
80
|
-
last_separator = options.fetch(:last_separator, ' and ')
|
81
|
-
|
82
|
-
case values.count
|
83
|
-
when 0
|
84
|
-
''
|
85
|
-
when 1
|
86
|
-
values.first.to_s
|
87
|
-
when 2
|
88
|
-
"#{values[0]}#{last_separator}#{values[1]}"
|
89
|
-
else
|
90
|
-
if last_separator =~ /\A,?\s*/
|
91
|
-
last_separator = last_separator.sub /\A,?\s*/, separator
|
92
|
-
else
|
93
|
-
last_separator = "#{separator}#{last_separator}"
|
94
|
-
end # if-else
|
95
|
-
|
96
|
-
"#{values[0...-1].join(separator)}#{last_separator}#{values.last}"
|
97
|
-
end # case
|
98
|
-
end # method humanize_list
|
99
|
-
end # module
|
6
|
+
# Alias for ArrayTools to ensure backward compatibility.
|
7
|
+
EnumerableTools = ArrayTools
|
100
8
|
end # module
|
@@ -0,0 +1,23 @@
|
|
1
|
+
# lib/sleeping_king_studios/tools/hash_tools.rb
|
2
|
+
|
3
|
+
require 'sleeping_king_studios/tools'
|
4
|
+
require 'sleeping_king_studios/tools/object_tools'
|
5
|
+
|
6
|
+
module SleepingKingStudios::Tools
|
7
|
+
# Tools for working with hash-like enumerable objects.
|
8
|
+
module HashTools
|
9
|
+
extend self
|
10
|
+
|
11
|
+
# Creates a deep copy of the object by returning a new Hash with deep
|
12
|
+
# copies of each key and value.
|
13
|
+
#
|
14
|
+
# @param [Hash<Object>] hsh The hash to copy.
|
15
|
+
#
|
16
|
+
# @return [Hash] The copy of the hash.
|
17
|
+
def deep_dup hsh
|
18
|
+
hsh.each.with_object(Hash.new) do |(key, value), copy|
|
19
|
+
copy[ObjectTools.deep_dup key] = ObjectTools.deep_dup(value)
|
20
|
+
end # each
|
21
|
+
end # method deep_dup
|
22
|
+
end # module
|
23
|
+
end # module
|
@@ -37,6 +37,27 @@ module SleepingKingStudios::Tools
|
|
37
37
|
end
|
38
38
|
end # method apply
|
39
39
|
|
40
|
+
# Creates a deep copy of the object. If the object is an Array, returns a
|
41
|
+
# new Array with deep copies of each array item. If the object is a Hash,
|
42
|
+
# returns a new Hash with deep copies of each hash key and value. Otherwise,
|
43
|
+
# returns Object#dup.
|
44
|
+
#
|
45
|
+
# @param [Object] obj The object to copy.
|
46
|
+
#
|
47
|
+
# @return The copy of the object.
|
48
|
+
def deep_dup obj
|
49
|
+
case obj
|
50
|
+
when FalseClass, Fixnum, Float, NilClass, Symbol, TrueClass
|
51
|
+
obj
|
52
|
+
when Array
|
53
|
+
ArrayTools.deep_dup obj
|
54
|
+
when Hash
|
55
|
+
HashTools.deep_dup obj
|
56
|
+
else
|
57
|
+
obj.respond_to?(:deep_dup) ? obj.deep_dup : obj.dup
|
58
|
+
end # case
|
59
|
+
end # method deep_dup
|
60
|
+
|
40
61
|
# Returns the object's eigenclass.
|
41
62
|
#
|
42
63
|
# @param [Object] object The object for which an eigenclass is required.
|
@@ -48,3 +69,6 @@ module SleepingKingStudios::Tools
|
|
48
69
|
alias_method :metaclass, :eigenclass
|
49
70
|
end # module
|
50
71
|
end # module
|
72
|
+
|
73
|
+
require 'sleeping_king_studios/tools/array_tools'
|
74
|
+
require 'sleeping_king_studios/tools/hash_tools'
|
@@ -20,9 +20,6 @@ module SleepingKingStudios
|
|
20
20
|
#
|
21
21
|
# @see http://semver.org
|
22
22
|
module SemanticVersion
|
23
|
-
# @api private
|
24
|
-
FETCH_DEFAULT = Object.new.freeze
|
25
|
-
|
26
23
|
# Error class for handling missing constants in a version definition.
|
27
24
|
class InvalidVersionError < StandardError; end
|
28
25
|
|
@@ -97,6 +94,8 @@ module SleepingKingStudios
|
|
97
94
|
|
98
95
|
private
|
99
96
|
|
97
|
+
FETCH_DEFAULT = Object.new.freeze
|
98
|
+
|
100
99
|
def const_fetch name, default = FETCH_DEFAULT
|
101
100
|
if self.const_defined?(name)
|
102
101
|
return self.const_get(name).to_s
|
@@ -10,9 +10,13 @@ module SleepingKingStudios
|
|
10
10
|
module Version
|
11
11
|
extend SleepingKingStudios::Tools::SemanticVersion
|
12
12
|
|
13
|
+
private
|
14
|
+
|
13
15
|
MAJOR = 0
|
14
|
-
MINOR =
|
15
|
-
PATCH =
|
16
|
+
MINOR = 2
|
17
|
+
PATCH = 0
|
18
|
+
PRERELEASE = 'beta'
|
19
|
+
BUILD = 0
|
16
20
|
end # module
|
17
21
|
|
18
22
|
VERSION = Version.to_gem_version
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sleeping_king_studios-tools
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0.beta.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Rob "Merlin" Smith
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-02-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake
|
@@ -16,60 +16,68 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: '10.
|
20
|
-
- - ">="
|
21
|
-
- !ruby/object:Gem::Version
|
22
|
-
version: 0.10.3.2
|
19
|
+
version: '10.5'
|
23
20
|
type: :development
|
24
21
|
prerelease: false
|
25
22
|
version_requirements: !ruby/object:Gem::Requirement
|
26
23
|
requirements:
|
27
24
|
- - "~>"
|
28
25
|
- !ruby/object:Gem::Version
|
29
|
-
version: '10.
|
30
|
-
|
26
|
+
version: '10.5'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: rspec
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
31
32
|
- !ruby/object:Gem::Version
|
32
|
-
version:
|
33
|
+
version: '3.4'
|
34
|
+
type: :development
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '3.4'
|
33
41
|
- !ruby/object:Gem::Dependency
|
34
|
-
name:
|
42
|
+
name: byebug
|
35
43
|
requirement: !ruby/object:Gem::Requirement
|
36
44
|
requirements:
|
37
45
|
- - "~>"
|
38
46
|
- !ruby/object:Gem::Version
|
39
|
-
version: '
|
47
|
+
version: '8.2'
|
40
48
|
- - ">="
|
41
49
|
- !ruby/object:Gem::Version
|
42
|
-
version:
|
50
|
+
version: 8.2.2
|
43
51
|
type: :development
|
44
52
|
prerelease: false
|
45
53
|
version_requirements: !ruby/object:Gem::Requirement
|
46
54
|
requirements:
|
47
55
|
- - "~>"
|
48
56
|
- !ruby/object:Gem::Version
|
49
|
-
version: '
|
57
|
+
version: '8.2'
|
50
58
|
- - ">="
|
51
59
|
- !ruby/object:Gem::Version
|
52
|
-
version:
|
60
|
+
version: 8.2.2
|
53
61
|
- !ruby/object:Gem::Dependency
|
54
|
-
name: rspec
|
62
|
+
name: rspec-sleeping_king_studios
|
55
63
|
requirement: !ruby/object:Gem::Requirement
|
56
64
|
requirements:
|
57
65
|
- - "~>"
|
58
66
|
- !ruby/object:Gem::Version
|
59
|
-
version: '
|
67
|
+
version: '2.1'
|
60
68
|
- - ">="
|
61
69
|
- !ruby/object:Gem::Version
|
62
|
-
version:
|
70
|
+
version: 2.1.1
|
63
71
|
type: :development
|
64
72
|
prerelease: false
|
65
73
|
version_requirements: !ruby/object:Gem::Requirement
|
66
74
|
requirements:
|
67
75
|
- - "~>"
|
68
76
|
- !ruby/object:Gem::Version
|
69
|
-
version: '
|
77
|
+
version: '2.1'
|
70
78
|
- - ">="
|
71
79
|
- !ruby/object:Gem::Version
|
72
|
-
version:
|
80
|
+
version: 2.1.1
|
73
81
|
description: |
|
74
82
|
A library of utility services and concerns to expand the functionality of core
|
75
83
|
classes without polluting the global namespace.
|
@@ -83,7 +91,9 @@ files:
|
|
83
91
|
- LICENSE
|
84
92
|
- README.md
|
85
93
|
- lib/sleeping_king_studios/tools.rb
|
94
|
+
- lib/sleeping_king_studios/tools/array_tools.rb
|
86
95
|
- lib/sleeping_king_studios/tools/enumerable_tools.rb
|
96
|
+
- lib/sleeping_king_studios/tools/hash_tools.rb
|
87
97
|
- lib/sleeping_king_studios/tools/integer_tools.rb
|
88
98
|
- lib/sleeping_king_studios/tools/object_tools.rb
|
89
99
|
- lib/sleeping_king_studios/tools/semantic_version.rb
|
@@ -104,9 +114,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
104
114
|
version: '0'
|
105
115
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
106
116
|
requirements:
|
107
|
-
- - "
|
117
|
+
- - ">"
|
108
118
|
- !ruby/object:Gem::Version
|
109
|
-
version:
|
119
|
+
version: 1.3.1
|
110
120
|
requirements: []
|
111
121
|
rubyforge_project:
|
112
122
|
rubygems_version: 2.5.1
|
@@ -114,3 +124,4 @@ signing_key:
|
|
114
124
|
specification_version: 4
|
115
125
|
summary: A library of utility services and concerns.
|
116
126
|
test_files: []
|
127
|
+
has_rdoc:
|