auser-columbus 0.0.1 → 0.0.2
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.
- data/VERSION.yml +1 -1
- data/bin/columbus-client +15 -7
- data/bin/columbus-server +1 -1
- metadata +2 -2
data/VERSION.yml
CHANGED
data/bin/columbus-client
CHANGED
@@ -12,19 +12,27 @@ Usage: #{$0} #{all_options_string} COMMAND [ARGS]
|
|
12
12
|
EOS
|
13
13
|
|
14
14
|
opt :discover_type, "Type of discovery message", :default => nil
|
15
|
-
opt :query, "Query to perform on the service"
|
15
|
+
opt :query, "Query to perform on the service", :type => String
|
16
|
+
opt :select, "Select the first that responds to this selection", :type => String
|
16
17
|
|
17
18
|
run do |command|
|
18
19
|
|
19
20
|
Columbus::Client.discover_type = command[:discover_type] unless command[:discover_type].nil?
|
20
21
|
|
21
22
|
# Columbus::Client.list
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
23
|
+
if command[:select]
|
24
|
+
s = Columbus::Client.service_list.select do |s|
|
25
|
+
s if s.name =~ /#{command[:select]}/
|
26
|
+
end
|
27
|
+
puts "#{s.name}\t#{s.host}\t#{s.port}\t#{s.description}" unless s.empty?
|
28
|
+
else
|
29
|
+
Columbus::Client.service_list.each do |s|
|
30
|
+
if command[:query]
|
31
|
+
puts s.send(command[:query].to_sym)
|
32
|
+
else
|
33
|
+
puts "#{s.name}\t#{s.host}\t#{s.port}\t#{s.description}"
|
34
|
+
end
|
35
|
+
end
|
28
36
|
end
|
29
37
|
|
30
38
|
end
|
data/bin/columbus-server
CHANGED
@@ -12,7 +12,7 @@ Usage: #{$0} #{all_options_string} COMMAND [ARGS]
|
|
12
12
|
EOS
|
13
13
|
|
14
14
|
opt :interface, "The interface to pull from", :default => "vmnet8"
|
15
|
-
opt :name, "Name to broadcast", :type => String
|
15
|
+
opt :name, "Name to broadcast", :type => String, :default => "columbus-server"
|
16
16
|
opt :description, "Description to broadcast", :type => String
|
17
17
|
|
18
18
|
run do |command|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: auser-columbus
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ari Lerner
|
@@ -9,7 +9,7 @@ autorequire:
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2009-
|
12
|
+
date: 2009-06-01 00:00:00 -07:00
|
13
13
|
default_executable:
|
14
14
|
dependencies: []
|
15
15
|
|