mushy 0.6.0 → 0.11.0
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/lib/mushy.rb +10 -3
- data/lib/mushy/builder/api.rb +4 -4
- data/lib/mushy/flow.rb +14 -1
- data/lib/mushy/flux.rb +4 -5
- data/lib/mushy/fluxs/collection.rb +33 -15
- data/lib/mushy/fluxs/global_variables.rb +39 -0
- data/lib/mushy/fluxs/pdf.rb +6 -3
- data/lib/mushy/fluxs/sense_hat_environmental_sensors.rb +56 -0
- data/lib/mushy/fluxs/simple_python_program.rb +32 -0
- data/lib/mushy/fluxs/smtp.rb +43 -37
- data/lib/mushy/masher.rb +9 -1
- data/lib/mushy/runner.rb +6 -4
- data/lib/site.rb +1 -1
- data/mushy.gemspec +12 -12
- metadata +48 -45
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a7e8090ce2ca66c9aff11ada4b9beee80bb7866dcd27d51b618c1cfa699b2d4f
|
4
|
+
data.tar.gz: b9849eca063fa80c99e465c498994c04796245e01c79762338616563e484c312
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b632030b6ce53a9364e6861b466e6574cd9f2e5836964db87a4124109bb4e0c23d801c448b40b1270e367cc2ab7eecb04b4ef94fa86ae844e1626f2a97471f52
|
7
|
+
data.tar.gz: 421e022ab044af27b72b2380be9343c22fa94c435388512712045f717af46c3ee10a2524e2784aff5bfb5c0e1bbe3a255b73a47ab38d514e17bb9307b626dad2
|
data/lib/mushy.rb
CHANGED
@@ -3,9 +3,16 @@ require 'symbolized'
|
|
3
3
|
|
4
4
|
Dir[File.dirname(__FILE__) + '/mushy/*.rb'].each { |f| require f }
|
5
5
|
|
6
|
-
important_flux_files = [
|
6
|
+
important_flux_files = [
|
7
|
+
'bash',
|
8
|
+
'browser',
|
9
|
+
'simple_python_program',
|
10
|
+
].map { |x| "#{x}.rb" }
|
11
|
+
|
7
12
|
Dir[File.dirname(__FILE__) + '/mushy/fluxs/*.rb']
|
8
|
-
.
|
9
|
-
.
|
13
|
+
.map { |x| [x, important_flux_files.find_index(x.split("\/")[-1]) || 9999999] }
|
14
|
+
.sort_by { |x| x[1] }
|
15
|
+
.map { |x| x[0] }
|
16
|
+
.each { |f| require f }
|
10
17
|
|
11
18
|
Dir[File.dirname(__FILE__) + '/mushy/builder/*.rb'].each { |f| require f }
|
data/lib/mushy/builder/api.rb
CHANGED
@@ -23,15 +23,15 @@ module Mushy
|
|
23
23
|
|
24
24
|
def self.save file, data
|
25
25
|
|
26
|
-
file = "#{file}.
|
26
|
+
file = "#{file}.mushy" unless file.downcase.end_with?('.mushy')
|
27
27
|
|
28
28
|
data = SymbolizedHash.new JSON.parse(data)
|
29
|
-
Mushy::WriteFile.new.process( {}, { name: file, data: data
|
29
|
+
Mushy::WriteFile.new.process( {}, { name: file, data: JSON.pretty_generate(data) })
|
30
30
|
|
31
31
|
end
|
32
32
|
|
33
33
|
def self.start file, event
|
34
|
-
file = "#{file}.
|
34
|
+
file = "#{file}.mushy" unless file.downcase.end_with?('.mushy')
|
35
35
|
flow = File.open(file).read
|
36
36
|
flow = Mushy::Flow.parse flow
|
37
37
|
|
@@ -78,7 +78,7 @@ module Mushy
|
|
78
78
|
|
79
79
|
def self.get_flow file
|
80
80
|
puts "trying to get: #{file}"
|
81
|
-
file = "#{file}.
|
81
|
+
file = "#{file}.mushy" unless file.downcase.end_with?('.mushy')
|
82
82
|
data = JSON.parse File.open(file).read
|
83
83
|
data['fluxs']
|
84
84
|
.reject { |x| x['parents'] }
|
data/lib/mushy/flow.rb
CHANGED
@@ -17,15 +17,28 @@ module Mushy
|
|
17
17
|
.flatten
|
18
18
|
end
|
19
19
|
|
20
|
+
def adjust_data data
|
21
|
+
fluxs
|
22
|
+
.select { |x| x.respond_to? :adjust_data }
|
23
|
+
.reduce(data) { |t, i| i.adjust_data t }
|
24
|
+
end
|
25
|
+
|
20
26
|
def self.build_flux record
|
21
27
|
type = record[:type] || record['type'] || record[:flux] || record['flux'] || 'Flux'
|
22
28
|
flux = Object.const_get("Mushy::#{type}").new
|
23
29
|
flux.id = record[:id] || record['id'] || flux.id
|
24
30
|
flux.type = type
|
25
31
|
flux.config = SymbolizedHash.new(record[:config] || record['config'])
|
32
|
+
flux.flow = Mushy::Flow.new
|
26
33
|
flux
|
27
34
|
end
|
28
35
|
|
36
|
+
def build_flux record
|
37
|
+
Mushy::Flow.build_flux(record).tap do |flux|
|
38
|
+
flux.flow = self
|
39
|
+
end
|
40
|
+
end
|
41
|
+
|
29
42
|
def self.parse data
|
30
43
|
data = JSON.parse data
|
31
44
|
|
@@ -34,7 +47,7 @@ module Mushy
|
|
34
47
|
|
35
48
|
flow = new
|
36
49
|
|
37
|
-
flow.fluxs = data_fluxs.map { |s| build_flux s }
|
50
|
+
flow.fluxs = data_fluxs.map { |s| flow.build_flux s }
|
38
51
|
|
39
52
|
fluxs_with_parent_ids = flow.fluxs.reduce({}) { |t, i| t[i.id] = []; t }
|
40
53
|
data_fluxs.map { |r| fluxs_with_parent_ids[r['id']] = r['parents'] || [] }
|
data/lib/mushy/flux.rb
CHANGED
@@ -8,6 +8,7 @@ module Mushy
|
|
8
8
|
attr_accessor :subscribed_to
|
9
9
|
attr_accessor :config
|
10
10
|
attr_accessor :masher
|
11
|
+
attr_accessor :flow
|
11
12
|
|
12
13
|
def initialize
|
13
14
|
guard
|
@@ -39,20 +40,18 @@ module Mushy
|
|
39
40
|
|
40
41
|
incoming_event = SymbolizedHash.new(incoming_event) if incoming_event.is_a?(Hash)
|
41
42
|
|
42
|
-
|
43
|
-
|
44
|
-
incoming_split = masher.mash(config, event)[:incoming_split]
|
43
|
+
incoming_split = masher.mash(config, incoming_event)[:incoming_split]
|
45
44
|
config_considering_an_imcoming_split = config
|
46
45
|
.reject { |x, _| incoming_split && x.to_s == 'join' }
|
47
46
|
.reduce({}) { |t, i| t[i[0]] = i[1]; t }
|
48
47
|
|
49
|
-
events = incoming_split ? incoming_event[incoming_split] : [
|
48
|
+
events = incoming_split ? incoming_event[incoming_split] : [incoming_event]
|
50
49
|
|
51
50
|
results = events.map { |e| execute_single_event e, config_considering_an_imcoming_split }
|
52
51
|
|
53
52
|
return results.first unless incoming_split
|
54
53
|
|
55
|
-
results = join_these_results([results].flatten,
|
54
|
+
results = join_these_results([results].flatten, incoming_event, config[:join]) if config[:join]
|
56
55
|
|
57
56
|
results.flatten
|
58
57
|
end
|
@@ -2,8 +2,6 @@ module Mushy
|
|
2
2
|
|
3
3
|
class Collection < Flux
|
4
4
|
|
5
|
-
attr_accessor :collection
|
6
|
-
|
7
5
|
def self.details
|
8
6
|
{
|
9
7
|
name: 'Collection',
|
@@ -11,9 +9,14 @@ module Mushy
|
|
11
9
|
config: {
|
12
10
|
id: {
|
13
11
|
description: 'The path to the unique id in the body of the element.',
|
14
|
-
type: '
|
15
|
-
value: {
|
12
|
+
type: 'text',
|
13
|
+
value: '{{id}}',
|
16
14
|
},
|
15
|
+
collection_name: {
|
16
|
+
description: 'The name of the collection to interact with.',
|
17
|
+
type: 'text',
|
18
|
+
value: 'records',
|
19
|
+
},
|
17
20
|
operation: {
|
18
21
|
description: 'Perform this operation.',
|
19
22
|
type: 'select',
|
@@ -24,31 +27,26 @@ module Mushy
|
|
24
27
|
}
|
25
28
|
end
|
26
29
|
|
27
|
-
def initialize
|
28
|
-
self.collection = {}
|
29
|
-
super
|
30
|
-
end
|
31
|
-
|
32
30
|
def process event, config
|
33
31
|
self.send(config[:operation].to_sym, event, config)
|
34
32
|
end
|
35
33
|
|
36
34
|
def get_the_id event, config
|
37
|
-
|
35
|
+
config[:id]
|
38
36
|
end
|
39
37
|
|
40
38
|
def all event, config
|
41
|
-
|
39
|
+
the_collection(config).values
|
42
40
|
end
|
43
41
|
|
44
42
|
def delete event, config
|
45
|
-
|
43
|
+
the_collection(config).delete get_the_id(event, config)
|
46
44
|
event[config[:operation_performed]] = 'deleted' if config[:operation_performed]
|
47
45
|
event
|
48
46
|
end
|
49
47
|
|
50
48
|
def upsert event, config
|
51
|
-
if
|
49
|
+
if the_collection(config)[get_the_id(event, config)]
|
52
50
|
update event, config
|
53
51
|
else
|
54
52
|
insert event, config
|
@@ -56,18 +54,38 @@ module Mushy
|
|
56
54
|
end
|
57
55
|
|
58
56
|
def update event, config
|
59
|
-
item =
|
57
|
+
item = the_collection(config)[get_the_id(event, config)]
|
60
58
|
event.each { |k, v| item[k] = v } if item
|
61
59
|
event[config[:operation_performed]] = (item ? 'updated' : 'not exist') if config[:operation_performed]
|
62
60
|
event
|
63
61
|
end
|
64
62
|
|
65
63
|
def insert event, config
|
66
|
-
|
64
|
+
the_collection(config)[get_the_id(event, config)] = event
|
67
65
|
event[config[:operation_performed]] = 'inserted' if config[:operation_performed]
|
68
66
|
event
|
69
67
|
end
|
70
68
|
|
69
|
+
def the_collection config
|
70
|
+
Mushy::Collection.guard_the_flow self.flow
|
71
|
+
the_collection_name = config[:collection_name]
|
72
|
+
|
73
|
+
get_the_collection the_collection_name
|
74
|
+
end
|
75
|
+
|
76
|
+
def get_the_collection name
|
77
|
+
found_collection = self.flow.collection_data[name]
|
78
|
+
return found_collection if found_collection
|
79
|
+
self.flow.collection_data[name] = SymbolizedHash.new
|
80
|
+
end
|
81
|
+
|
82
|
+
def self.guard_the_flow flow
|
83
|
+
return if flow.respond_to?(:collection_data)
|
84
|
+
|
85
|
+
flow.instance_eval { class << self; self end }.send(:attr_accessor, :collection_data)
|
86
|
+
flow.collection_data = {}
|
87
|
+
end
|
88
|
+
|
71
89
|
end
|
72
90
|
|
73
91
|
end
|
@@ -0,0 +1,39 @@
|
|
1
|
+
module Mushy
|
2
|
+
|
3
|
+
class GlobalVariables < Flux
|
4
|
+
|
5
|
+
attr_accessor :state
|
6
|
+
|
7
|
+
def self.details
|
8
|
+
{
|
9
|
+
name: 'GlobalVariables',
|
10
|
+
description: 'Add global variables.',
|
11
|
+
config: {
|
12
|
+
values: {
|
13
|
+
description: 'Provide key/value pairs that will be set as global variables.',
|
14
|
+
label: 'Variables',
|
15
|
+
type: 'keyvalue',
|
16
|
+
value: {},
|
17
|
+
},
|
18
|
+
},
|
19
|
+
}
|
20
|
+
end
|
21
|
+
|
22
|
+
def initialize
|
23
|
+
super
|
24
|
+
self.state = SymbolizedHash.new
|
25
|
+
end
|
26
|
+
|
27
|
+
def adjust_data data
|
28
|
+
state.merge data
|
29
|
+
end
|
30
|
+
|
31
|
+
def process event, config
|
32
|
+
values = config[:values] || SymbolizedHash.new
|
33
|
+
state.merge! values
|
34
|
+
event
|
35
|
+
end
|
36
|
+
|
37
|
+
end
|
38
|
+
|
39
|
+
end
|
data/lib/mushy/fluxs/pdf.rb
CHANGED
@@ -4,8 +4,8 @@ module Mushy
|
|
4
4
|
|
5
5
|
def self.details
|
6
6
|
details = Browser.details
|
7
|
-
details[
|
8
|
-
details[
|
7
|
+
details[:name] = 'Pdf'
|
8
|
+
details[:description] = 'Turn a URL into a PDF.'
|
9
9
|
|
10
10
|
details[:config][:path] = {
|
11
11
|
description: 'The path of the PDF file to save.',
|
@@ -37,7 +37,10 @@ module Mushy
|
|
37
37
|
|
38
38
|
the_browser.pdf options
|
39
39
|
|
40
|
-
|
40
|
+
{
|
41
|
+
options: options,
|
42
|
+
file: Mushy::Ls.new.process({}, { path: options[:path] })[0]
|
43
|
+
}
|
41
44
|
|
42
45
|
end
|
43
46
|
|
@@ -0,0 +1,56 @@
|
|
1
|
+
module Mushy
|
2
|
+
|
3
|
+
class SenseHatEnvironmentalSensors < SimplePythonProgram
|
4
|
+
|
5
|
+
def self.details
|
6
|
+
{
|
7
|
+
name: 'SenseHatEnvironmentalSensors',
|
8
|
+
description: 'Pull values from the Sense HAT environmental sensors.',
|
9
|
+
config: Mushy::SimplePythonProgram.default_config,
|
10
|
+
}.tap do |c|
|
11
|
+
measurements
|
12
|
+
.sort_by { |x| default_measurements.include?(x) ? 0 : 1 }
|
13
|
+
.each do |measurement|
|
14
|
+
c[:config][measurement] = {
|
15
|
+
description: "Pull #{measurement}.",
|
16
|
+
type: 'boolean',
|
17
|
+
shrink: true,
|
18
|
+
value: default_measurements.include?(measurement) ? 'true' : '',
|
19
|
+
}
|
20
|
+
end
|
21
|
+
end
|
22
|
+
end
|
23
|
+
|
24
|
+
def self.measurements
|
25
|
+
[
|
26
|
+
:humidity,
|
27
|
+
:temperature,
|
28
|
+
:temperature_from_humidity,
|
29
|
+
:temperature_from_pressure,
|
30
|
+
:pressure,
|
31
|
+
]
|
32
|
+
end
|
33
|
+
|
34
|
+
def self.default_measurements
|
35
|
+
[:humidity, :temperature, :pressure]
|
36
|
+
end
|
37
|
+
|
38
|
+
def python_program event, config
|
39
|
+
values = self.class.measurements
|
40
|
+
.select { |x| config[x] == 'true' }
|
41
|
+
.reduce({}) { |t, i| t[i] = "get_#{i}"; t}
|
42
|
+
.map { |m| "\"#{m[0]}\": sense.#{m[1]}()" }
|
43
|
+
.join(',')
|
44
|
+
|
45
|
+
<<PYTHON
|
46
|
+
from sense_hat import SenseHat
|
47
|
+
import json
|
48
|
+
sense = SenseHat()
|
49
|
+
value = json.dumps({#{values}})
|
50
|
+
print(value)
|
51
|
+
PYTHON
|
52
|
+
end
|
53
|
+
|
54
|
+
end
|
55
|
+
|
56
|
+
end
|
@@ -0,0 +1,32 @@
|
|
1
|
+
module Mushy
|
2
|
+
|
3
|
+
class SimplePythonProgram < Bash
|
4
|
+
|
5
|
+
def self.default_config
|
6
|
+
Mushy::Bash.details[:config].tap do |config|
|
7
|
+
config.delete :command
|
8
|
+
config.delete :directory
|
9
|
+
end
|
10
|
+
end
|
11
|
+
|
12
|
+
def process event, config
|
13
|
+
|
14
|
+
lines = python_program(event, config)
|
15
|
+
.split('\n')
|
16
|
+
.map { |x| x.rstrip }
|
17
|
+
.select { |x| x && x != '' }
|
18
|
+
.map { |x| x.gsub('"', '\"') }
|
19
|
+
|
20
|
+
config[:command] = "python -c \"#{lines.join(';')}\""
|
21
|
+
|
22
|
+
result = super event, config
|
23
|
+
|
24
|
+
return nil unless result[:success]
|
25
|
+
|
26
|
+
JSON.parse result[:text]
|
27
|
+
|
28
|
+
end
|
29
|
+
|
30
|
+
end
|
31
|
+
|
32
|
+
end
|
data/lib/mushy/fluxs/smtp.rb
CHANGED
@@ -1,8 +1,50 @@
|
|
1
1
|
require 'pony'
|
2
2
|
|
3
3
|
module Mushy
|
4
|
+
|
5
|
+
class EmailBase < Flux
|
6
|
+
|
7
|
+
def process event, config
|
8
|
+
options = adjust(cleanup({
|
9
|
+
from: config[:from],
|
10
|
+
to: config[:to],
|
11
|
+
subject: config[:subject],
|
12
|
+
body: config[:body],
|
13
|
+
html_body: config[:html_body],
|
14
|
+
via_options: get_via_options_from(config)
|
15
|
+
}))
|
16
|
+
|
17
|
+
if (config[:attachment_file].to_s != '')
|
18
|
+
options[:attachments] = { config[:attachment_file].split("\/")[-1] => File.read(config[:attachment_file]) }
|
19
|
+
end
|
20
|
+
|
21
|
+
result = Pony.mail options
|
22
|
+
options.tap { |x| x.delete(:via_options) }
|
23
|
+
end
|
24
|
+
|
25
|
+
def adjust options
|
26
|
+
end
|
27
|
+
|
28
|
+
def cleanup options
|
29
|
+
options.tap do |hash|
|
30
|
+
hash.delete_if { |_, v| v.to_s == '' }
|
31
|
+
end
|
32
|
+
end
|
33
|
+
|
34
|
+
def get_via_options_from config
|
35
|
+
{
|
36
|
+
address: config[:address],
|
37
|
+
port: config[:port].to_s,
|
38
|
+
user_name: config[:username],
|
39
|
+
password: config[:password],
|
40
|
+
domain: config[:domain],
|
41
|
+
authentication: :plain,
|
42
|
+
enable_starttls_auto: true,
|
43
|
+
}
|
44
|
+
end
|
45
|
+
end
|
4
46
|
|
5
|
-
class Smtp <
|
47
|
+
class Smtp < EmailBase
|
6
48
|
|
7
49
|
def self.details
|
8
50
|
{
|
@@ -70,46 +112,10 @@ module Mushy
|
|
70
112
|
}
|
71
113
|
end
|
72
114
|
|
73
|
-
def process event, config
|
74
|
-
options = adjust(cleanup({
|
75
|
-
from: config[:from],
|
76
|
-
to: config[:to],
|
77
|
-
subject: config[:subject],
|
78
|
-
body: config[:body],
|
79
|
-
html_body: config[:html_body],
|
80
|
-
via_options: get_via_options_from(config)
|
81
|
-
}))
|
82
|
-
|
83
|
-
if (config[:attachment_file].to_s != '')
|
84
|
-
options[:attachments] = { config[:attachment_file].split("\/")[-1] => File.read(config[:attachment_file]) }
|
85
|
-
end
|
86
|
-
|
87
|
-
result = Pony.mail options
|
88
|
-
options.tap { |x| x.delete(:via_options) }
|
89
|
-
end
|
90
|
-
|
91
115
|
def adjust options
|
92
116
|
options.tap { |x| x[:via] = 'smtp' }
|
93
117
|
end
|
94
118
|
|
95
|
-
def cleanup options
|
96
|
-
options.tap do |hash|
|
97
|
-
hash.delete_if { |_, v| v.to_s == '' }
|
98
|
-
end
|
99
|
-
end
|
100
|
-
|
101
|
-
def get_via_options_from config
|
102
|
-
{
|
103
|
-
address: config[:address],
|
104
|
-
port: config[:port].to_s,
|
105
|
-
user_name: config[:username],
|
106
|
-
password: config[:password],
|
107
|
-
domain: config[:domain],
|
108
|
-
authentication: :plain,
|
109
|
-
enable_starttls_auto: true,
|
110
|
-
}
|
111
|
-
end
|
112
|
-
|
113
119
|
end
|
114
120
|
|
115
121
|
end
|
data/lib/mushy/masher.rb
CHANGED
@@ -45,7 +45,15 @@ module Mushy
|
|
45
45
|
segments = key.split '.'
|
46
46
|
|
47
47
|
segments.each do |segment|
|
48
|
-
|
48
|
+
if segment.include?('[') && segment.include?(']')
|
49
|
+
the_splits = segment.split('[')
|
50
|
+
segment = the_splits[0]
|
51
|
+
index = the_splits[1].sub(']', '')
|
52
|
+
data = data.is_a?(Hash) ? (data[segment] || data[segment.to_sym]) : (data ? data.send(segment.to_sym) : nil)
|
53
|
+
data = data[index.to_i]
|
54
|
+
else
|
55
|
+
data = data.is_a?(Hash) ? (data[segment] || data[segment.to_sym]) : (data ? data.send(segment.to_sym) : nil)
|
56
|
+
end
|
49
57
|
end
|
50
58
|
|
51
59
|
data
|
data/lib/mushy/runner.rb
CHANGED
@@ -12,7 +12,7 @@ module Mushy
|
|
12
12
|
run = find_run flux, flow
|
13
13
|
starting_event = build_event event_data, flow.id, run.id, flux.id
|
14
14
|
|
15
|
-
events = run_event_with_flux starting_event, flux
|
15
|
+
events = run_event_with_flux starting_event, flux, flow
|
16
16
|
|
17
17
|
while events.any?
|
18
18
|
events = events.map { |e| runner.run_event_in_flow e, flow }.flatten
|
@@ -23,12 +23,14 @@ module Mushy
|
|
23
23
|
|
24
24
|
def run_event_in_flow event, flow
|
25
25
|
flow.fluxs_for(event)
|
26
|
-
.map { |s| runner.run_event_with_flux event, s }
|
26
|
+
.map { |s| runner.run_event_with_flux event, s, flow }
|
27
27
|
.flatten
|
28
28
|
end
|
29
29
|
|
30
|
-
def run_event_with_flux event, flux
|
31
|
-
|
30
|
+
def run_event_with_flux event, flux, flow
|
31
|
+
data = event.data
|
32
|
+
data = flow.adjust_data data
|
33
|
+
[flux.execute(data)]
|
32
34
|
.flatten
|
33
35
|
.reject { |x| x.nil? }
|
34
36
|
.map { |x| x.is_a?(Hash) ? build_event(x, event.flow_id, event.run_id, flux.id) : x }
|
data/lib/site.rb
CHANGED
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.
|
7
|
+
s.version = '0.11.0'
|
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.'
|
@@ -16,15 +16,15 @@ Gem::Specification.new do |s|
|
|
16
16
|
s.homepage = 'https://cauthon.com'
|
17
17
|
s.license = 'MIT'
|
18
18
|
|
19
|
-
s.add_development_dependency 'minitest'
|
20
|
-
s.add_runtime_dependency 'sinatra'
|
21
|
-
s.add_runtime_dependency 'symbolized'
|
22
|
-
s.add_runtime_dependency 'thor'
|
23
|
-
s.add_runtime_dependency 'liquid'
|
24
|
-
s.add_runtime_dependency 'ferrum'
|
25
|
-
s.add_runtime_dependency 'nokogiri'
|
26
|
-
s.add_runtime_dependency 'faraday'
|
27
|
-
s.add_runtime_dependency 'pony'
|
28
|
-
s.add_runtime_dependency 'daemons'
|
29
|
-
s.add_runtime_dependency 'listen'
|
19
|
+
s.add_development_dependency 'minitest', '~> 5'
|
20
|
+
s.add_runtime_dependency 'sinatra', '~> 2.1'
|
21
|
+
s.add_runtime_dependency 'symbolized', '~> 0.0.1'
|
22
|
+
s.add_runtime_dependency 'thor', '~> 1.1'
|
23
|
+
s.add_runtime_dependency 'liquid', '~> 5'
|
24
|
+
s.add_runtime_dependency 'ferrum','~> 0.11'
|
25
|
+
s.add_runtime_dependency 'nokogiri', '~> 1'
|
26
|
+
s.add_runtime_dependency 'faraday', '~> 1'
|
27
|
+
s.add_runtime_dependency 'pony', '~> 1.13'
|
28
|
+
s.add_runtime_dependency 'daemons', '~> 1'
|
29
|
+
s.add_runtime_dependency 'listen', '~> 3.5'
|
30
30
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mushy
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.11.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Darren Cauthon
|
@@ -14,156 +14,156 @@ dependencies:
|
|
14
14
|
name: minitest
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- - "
|
17
|
+
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: '
|
19
|
+
version: '5'
|
20
20
|
type: :development
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
|
-
- - "
|
24
|
+
- - "~>"
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: '
|
26
|
+
version: '5'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: sinatra
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
|
-
- - "
|
31
|
+
- - "~>"
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: '
|
33
|
+
version: '2.1'
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
|
-
- - "
|
38
|
+
- - "~>"
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version: '
|
40
|
+
version: '2.1'
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: symbolized
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
44
44
|
requirements:
|
45
|
-
- - "
|
45
|
+
- - "~>"
|
46
46
|
- !ruby/object:Gem::Version
|
47
|
-
version:
|
47
|
+
version: 0.0.1
|
48
48
|
type: :runtime
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
|
-
- - "
|
52
|
+
- - "~>"
|
53
53
|
- !ruby/object:Gem::Version
|
54
|
-
version:
|
54
|
+
version: 0.0.1
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
56
|
name: thor
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
58
58
|
requirements:
|
59
|
-
- - "
|
59
|
+
- - "~>"
|
60
60
|
- !ruby/object:Gem::Version
|
61
|
-
version: '
|
61
|
+
version: '1.1'
|
62
62
|
type: :runtime
|
63
63
|
prerelease: false
|
64
64
|
version_requirements: !ruby/object:Gem::Requirement
|
65
65
|
requirements:
|
66
|
-
- - "
|
66
|
+
- - "~>"
|
67
67
|
- !ruby/object:Gem::Version
|
68
|
-
version: '
|
68
|
+
version: '1.1'
|
69
69
|
- !ruby/object:Gem::Dependency
|
70
70
|
name: liquid
|
71
71
|
requirement: !ruby/object:Gem::Requirement
|
72
72
|
requirements:
|
73
|
-
- - "
|
73
|
+
- - "~>"
|
74
74
|
- !ruby/object:Gem::Version
|
75
|
-
version: '
|
75
|
+
version: '5'
|
76
76
|
type: :runtime
|
77
77
|
prerelease: false
|
78
78
|
version_requirements: !ruby/object:Gem::Requirement
|
79
79
|
requirements:
|
80
|
-
- - "
|
80
|
+
- - "~>"
|
81
81
|
- !ruby/object:Gem::Version
|
82
|
-
version: '
|
82
|
+
version: '5'
|
83
83
|
- !ruby/object:Gem::Dependency
|
84
84
|
name: ferrum
|
85
85
|
requirement: !ruby/object:Gem::Requirement
|
86
86
|
requirements:
|
87
|
-
- - "
|
87
|
+
- - "~>"
|
88
88
|
- !ruby/object:Gem::Version
|
89
|
-
version: '0'
|
89
|
+
version: '0.11'
|
90
90
|
type: :runtime
|
91
91
|
prerelease: false
|
92
92
|
version_requirements: !ruby/object:Gem::Requirement
|
93
93
|
requirements:
|
94
|
-
- - "
|
94
|
+
- - "~>"
|
95
95
|
- !ruby/object:Gem::Version
|
96
|
-
version: '0'
|
96
|
+
version: '0.11'
|
97
97
|
- !ruby/object:Gem::Dependency
|
98
98
|
name: nokogiri
|
99
99
|
requirement: !ruby/object:Gem::Requirement
|
100
100
|
requirements:
|
101
|
-
- - "
|
101
|
+
- - "~>"
|
102
102
|
- !ruby/object:Gem::Version
|
103
|
-
version: '
|
103
|
+
version: '1'
|
104
104
|
type: :runtime
|
105
105
|
prerelease: false
|
106
106
|
version_requirements: !ruby/object:Gem::Requirement
|
107
107
|
requirements:
|
108
|
-
- - "
|
108
|
+
- - "~>"
|
109
109
|
- !ruby/object:Gem::Version
|
110
|
-
version: '
|
110
|
+
version: '1'
|
111
111
|
- !ruby/object:Gem::Dependency
|
112
112
|
name: faraday
|
113
113
|
requirement: !ruby/object:Gem::Requirement
|
114
114
|
requirements:
|
115
|
-
- - "
|
115
|
+
- - "~>"
|
116
116
|
- !ruby/object:Gem::Version
|
117
|
-
version: '
|
117
|
+
version: '1'
|
118
118
|
type: :runtime
|
119
119
|
prerelease: false
|
120
120
|
version_requirements: !ruby/object:Gem::Requirement
|
121
121
|
requirements:
|
122
|
-
- - "
|
122
|
+
- - "~>"
|
123
123
|
- !ruby/object:Gem::Version
|
124
|
-
version: '
|
124
|
+
version: '1'
|
125
125
|
- !ruby/object:Gem::Dependency
|
126
126
|
name: pony
|
127
127
|
requirement: !ruby/object:Gem::Requirement
|
128
128
|
requirements:
|
129
|
-
- - "
|
129
|
+
- - "~>"
|
130
130
|
- !ruby/object:Gem::Version
|
131
|
-
version: '
|
131
|
+
version: '1.13'
|
132
132
|
type: :runtime
|
133
133
|
prerelease: false
|
134
134
|
version_requirements: !ruby/object:Gem::Requirement
|
135
135
|
requirements:
|
136
|
-
- - "
|
136
|
+
- - "~>"
|
137
137
|
- !ruby/object:Gem::Version
|
138
|
-
version: '
|
138
|
+
version: '1.13'
|
139
139
|
- !ruby/object:Gem::Dependency
|
140
140
|
name: daemons
|
141
141
|
requirement: !ruby/object:Gem::Requirement
|
142
142
|
requirements:
|
143
|
-
- - "
|
143
|
+
- - "~>"
|
144
144
|
- !ruby/object:Gem::Version
|
145
|
-
version: '
|
145
|
+
version: '1'
|
146
146
|
type: :runtime
|
147
147
|
prerelease: false
|
148
148
|
version_requirements: !ruby/object:Gem::Requirement
|
149
149
|
requirements:
|
150
|
-
- - "
|
150
|
+
- - "~>"
|
151
151
|
- !ruby/object:Gem::Version
|
152
|
-
version: '
|
152
|
+
version: '1'
|
153
153
|
- !ruby/object:Gem::Dependency
|
154
154
|
name: listen
|
155
155
|
requirement: !ruby/object:Gem::Requirement
|
156
156
|
requirements:
|
157
|
-
- - "
|
157
|
+
- - "~>"
|
158
158
|
- !ruby/object:Gem::Version
|
159
|
-
version: '
|
159
|
+
version: '3.5'
|
160
160
|
type: :runtime
|
161
161
|
prerelease: false
|
162
162
|
version_requirements: !ruby/object:Gem::Requirement
|
163
163
|
requirements:
|
164
|
-
- - "
|
164
|
+
- - "~>"
|
165
165
|
- !ruby/object:Gem::Version
|
166
|
-
version: '
|
166
|
+
version: '3.5'
|
167
167
|
description: This tool assists in the creation and processing of workflows.
|
168
168
|
email: darren@cauthon.com
|
169
169
|
executables:
|
@@ -194,6 +194,7 @@ files:
|
|
194
194
|
- lib/mushy/fluxs/format.rb
|
195
195
|
- lib/mushy/fluxs/get.rb
|
196
196
|
- lib/mushy/fluxs/git_log.rb
|
197
|
+
- lib/mushy/fluxs/global_variables.rb
|
197
198
|
- lib/mushy/fluxs/interval.rb
|
198
199
|
- lib/mushy/fluxs/ls.rb
|
199
200
|
- lib/mushy/fluxs/parse_html.rb
|
@@ -203,6 +204,8 @@ files:
|
|
203
204
|
- lib/mushy/fluxs/read_csv.rb
|
204
205
|
- lib/mushy/fluxs/read_file.rb
|
205
206
|
- lib/mushy/fluxs/screenshot.rb
|
207
|
+
- lib/mushy/fluxs/sense_hat_environmental_sensors.rb
|
208
|
+
- lib/mushy/fluxs/simple_python_program.rb
|
206
209
|
- lib/mushy/fluxs/smtp.rb
|
207
210
|
- lib/mushy/fluxs/times.rb
|
208
211
|
- lib/mushy/fluxs/write_file.rb
|