mushy 0.5.2 → 0.5.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/mushy/builder/api.rb +1 -0
- data/lib/mushy/flux.rb +8 -1
- data/lib/mushy/fluxs/ls.rb +2 -2
- data/mushy.gemspec +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 06d11ce2fc1a5da26f1272caf5b4b8a5bc7e8ff110b0169932778b9bdb7bb2bc
|
4
|
+
data.tar.gz: 96b68f95bff616ff46084d97630d0eab8d1496a99e902efae7fad965a16485dd
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: efc7c6b028efa5c75033b92ff9db8b422c6d81aae240a48178371b4208c1231ac63d8a2e437acfaccddb9e8a233c263b0284c85b16678036f99125f6ed757f6c
|
7
|
+
data.tar.gz: 5d19241ba64eddd10937f09aeb19d5c3d809d68e8ca100b7d94e64362e8a1a32fc0da56fabf7aeebd6f6303be5cce00db382333400f8e000c408535f63ad64f1
|
data/lib/mushy/builder/api.rb
CHANGED
@@ -93,6 +93,7 @@ module Mushy
|
|
93
93
|
details[:config][:limit] = { type: 'integer', shrink: true, description: 'Limit the number of events to this number.', default: '' }
|
94
94
|
details[:config][:join] = { type: 'text', shrink: true, description: 'Join all of the events from this flux into one event, under this name.', default: '' }
|
95
95
|
details[:config][:sort] = { type: 'text', shrink: true, description: 'Sort by this key.', default: '' }
|
96
|
+
details[:config][:ignore] = { type: 'text', shrink: true, description: 'Ignore these keys.', value: '', default: '' }
|
96
97
|
details[:config][:model] = { type: 'keyvalue', shrink: true, description: 'Reshape the outgoing events.', value: {}, default: {} }
|
97
98
|
|
98
99
|
details[:config][:error_strategy] = {
|
data/lib/mushy/flux.rb
CHANGED
@@ -91,7 +91,7 @@ module Mushy
|
|
91
91
|
end
|
92
92
|
|
93
93
|
def shape_these results, event, config
|
94
|
-
supported_shaping = [:merge, :outgoing_split, :group, :model, :join, :sort, :limit]
|
94
|
+
supported_shaping = [:merge, :outgoing_split, :group, :model, :ignore, :join, :sort, :limit]
|
95
95
|
|
96
96
|
shaping = supported_shaping
|
97
97
|
if (config[:shaping])
|
@@ -136,6 +136,13 @@ module Mushy
|
|
136
136
|
results.map { |x| masher.mash by, x }
|
137
137
|
end
|
138
138
|
|
139
|
+
def ignore_these_results results, event, by
|
140
|
+
return results if by.to_s == ''
|
141
|
+
ignore_fields = by.split ','
|
142
|
+
results.each { |r| ignore_fields.each { |f| r.delete f } }
|
143
|
+
results
|
144
|
+
end
|
145
|
+
|
139
146
|
def merge_these_results results, event, by
|
140
147
|
keys_to_merge = convert_this_to_an_array by
|
141
148
|
keys_to_merge = event.keys.map { |x| x.to_s } if (keys_to_merge[0] == '*')
|
data/lib/mushy/fluxs/ls.rb
CHANGED
@@ -41,7 +41,7 @@ module Mushy
|
|
41
41
|
arguments = ['-A', '-l', '--full-time', '-i']
|
42
42
|
arguments << '-R' if config[:recursive].to_s == 'true'
|
43
43
|
arguments << '-d' if config[:directory_only].to_s == 'true'
|
44
|
-
arguments << config[:path] if config[:path].to_s != ''
|
44
|
+
arguments << "'#{config[:path]}'" if config[:path].to_s != ''
|
45
45
|
arguments
|
46
46
|
end
|
47
47
|
|
@@ -107,7 +107,7 @@ module Mushy
|
|
107
107
|
r[:date] = Time.parse r[:date]
|
108
108
|
end
|
109
109
|
|
110
|
-
result[:name] = segments.
|
110
|
+
result[:name] = segments.join ' '
|
111
111
|
|
112
112
|
result.tap do |r|
|
113
113
|
help_segments = r[:help].split ''
|
data/mushy.gemspec
CHANGED
@@ -4,7 +4,7 @@ require 'mushy/version'
|
|
4
4
|
|
5
5
|
Gem::Specification.new do |s|
|
6
6
|
s.name = 'mushy'
|
7
|
-
s.version = '0.5.
|
7
|
+
s.version = '0.5.3'
|
8
8
|
s.date = '2020-11-23'
|
9
9
|
s.summary = 'Process streams of work using common modules.'
|
10
10
|
s.description = 'This tool assists in the creation and processing of workflows.'
|