rutty 2.3.2 → 2.4.0
Sign up to get free protection for your applications and to get access to all the features.
- data/Gemfile +8 -3
- data/Gemfile.lock +22 -11
- data/README.md +62 -5
- data/Rakefile +33 -27
- data/VERSION +1 -1
- data/bin/rutty +8 -8
- data/lib/rutty/actions.rb +171 -98
- data/lib/rutty/helpers.rb +33 -3
- data/lib/rutty/node.rb +13 -1
- data/lib/rutty/thread_pool/pool.rb +80 -0
- data/lib/rutty/thread_pool/worker.rb +103 -0
- data/lib/rutty/version.rb +2 -2
- data/rutty.gemspec +105 -54
- data/test/helper.rb +20 -4
- data/test/test_action_add_node.rb +2 -5
- data/test/test_action_dsh.rb +20 -19
- data/test/test_action_init.rb +4 -8
- data/test/test_action_list_nodes.rb +1 -4
- data/test/test_action_scp.rb +50 -0
- data/test/test_node.rb +13 -0
- data/test/test_nodes.rb +10 -1
- metadata +303 -50
- data/.gitignore +0 -24
data/test/helper.rb
CHANGED
@@ -7,7 +7,22 @@ $LOAD_PATH.unshift(File.dirname(__FILE__))
|
|
7
7
|
require 'rutty'
|
8
8
|
|
9
9
|
class Test::Unit::TestCase
|
10
|
-
|
10
|
+
# Terminal escape sequences for colors
|
11
|
+
module Colors
|
12
|
+
CLEAR = '\\e\[0m'
|
13
|
+
|
14
|
+
RED = '\\e\[31m'
|
15
|
+
YELLOW = '\\e\[33m'
|
16
|
+
GREEN = '\\e\[32m'
|
17
|
+
CYAN = '\\e\[36m'
|
18
|
+
|
19
|
+
RED_BG = '\\e\[41m'
|
20
|
+
|
21
|
+
BOLD = '\\e\[1m'
|
22
|
+
end
|
23
|
+
|
24
|
+
TMP_DIR = File.join(File.dirname(__FILE__), '..', 'tmp')
|
25
|
+
TEST_CONF_DIR = File.join(TMP_DIR, 'config')
|
11
26
|
TEST_GENERAL_CONF = File.join(TEST_CONF_DIR, 'defaults.yaml')
|
12
27
|
TEST_NODES_CONF = File.join(TEST_CONF_DIR, 'nodes.yaml')
|
13
28
|
|
@@ -20,16 +35,16 @@ class Test::Unit::TestCase
|
|
20
35
|
end
|
21
36
|
|
22
37
|
def clean_test_config!
|
23
|
-
%x(rm -rf #{
|
38
|
+
%x(rm -rf #{TMP_DIR}) if File.exists? TMP_DIR
|
24
39
|
end
|
25
40
|
|
26
41
|
def seed_nodes
|
27
|
-
out = %x(#{RUTTY_BIN} add_node localhost -c #{TEST_CONF_DIR} -k ~/.ssh/id_rsa -u #{ENV['USER']}
|
42
|
+
out = %x(#{RUTTY_BIN} add_node localhost -c #{TEST_CONF_DIR} -k ~/.ssh/id_rsa -u #{ENV['USER']} -g localhost,test -p 22)
|
28
43
|
assert_match /Added localhost/, out
|
29
44
|
end
|
30
45
|
|
31
46
|
def seed_bad_node
|
32
|
-
out = %x(#{RUTTY_BIN} add_node example.com -c #{TEST_CONF_DIR}
|
47
|
+
out = %x(#{RUTTY_BIN} add_node example.com -c #{TEST_CONF_DIR} -g example,test,broken)
|
33
48
|
assert_match /Added example\.com/, out
|
34
49
|
end
|
35
50
|
|
@@ -45,6 +60,7 @@ class Test::Unit::TestCase
|
|
45
60
|
end
|
46
61
|
end
|
47
62
|
|
63
|
+
# Used to make private methods in a class public temporarily.
|
48
64
|
class Class
|
49
65
|
def publicize_methods
|
50
66
|
saved_private_instance_methods = self.private_instance_methods
|
@@ -8,12 +8,9 @@ class TestActionAddNode < Test::Unit::TestCase
|
|
8
8
|
should "properly create a new node entry when called" do
|
9
9
|
require 'yaml'
|
10
10
|
|
11
|
-
output = %x(#{RUTTY_BIN} add_node -c #{TEST_CONF_DIR} example.com -k /home/user/.ssh/id_rsa -u root -p 22333
|
11
|
+
output = %x(#{RUTTY_BIN} add_node -c #{TEST_CONF_DIR} example.com -k /home/user/.ssh/id_rsa -u root -p 22333 -g example,testing)
|
12
12
|
|
13
|
-
|
14
|
-
clear = '\\e\[0m'
|
15
|
-
|
16
|
-
assert_match /#{green}Added example\.com#{clear}/, output
|
13
|
+
assert_match /#{Colors::GREEN}Added example\.com#{Colors::CLEAR}/, output
|
17
14
|
|
18
15
|
nodes = YAML.load(File.open(TEST_NODES_CONF).read)
|
19
16
|
|
data/test/test_action_dsh.rb
CHANGED
@@ -8,10 +8,7 @@ class TestActionDSH < Test::Unit::TestCase
|
|
8
8
|
should "report no defined nodes when no nodes defined" do
|
9
9
|
output = %x(#{RUTTY_BIN} -c #{TEST_CONF_DIR} -a uptime)
|
10
10
|
|
11
|
-
|
12
|
-
clear = '\\e\[0m'
|
13
|
-
|
14
|
-
assert_match /^#{yellow}No nodes defined#{clear}$/, output.rstrip
|
11
|
+
assert_match /^#{Colors::YELLOW}No nodes defined#{Colors::CLEAR}$/, output.rstrip
|
15
12
|
end
|
16
13
|
|
17
14
|
should "display a critical error state when unable to connect" do
|
@@ -19,35 +16,39 @@ class TestActionDSH < Test::Unit::TestCase
|
|
19
16
|
|
20
17
|
output = %x(#{RUTTY_BIN} -c #{TEST_CONF_DIR} -a uptime)
|
21
18
|
|
22
|
-
|
23
|
-
yellow = '\\e\[33m'
|
24
|
-
red = '\\e\[31m'
|
25
|
-
clear = '\\e\[0m'
|
26
|
-
|
27
|
-
assert_match /^#{yellow}#{red_bg}example\.com#{clear}\s+#{red}ERROR: Connection timeout#{clear}$/, output.rstrip
|
19
|
+
assert_match /^#{Colors::YELLOW}#{Colors::RED_BG}example\.com#{Colors::CLEAR}\s+#{Colors::RED}ERROR: Connection timeout#{Colors::CLEAR}$/, output.rstrip
|
28
20
|
end
|
29
21
|
|
30
|
-
should "display a general error state when an
|
22
|
+
should "display a general error state when an exit code > 0 is returned" do
|
31
23
|
seed_nodes
|
32
24
|
|
33
25
|
output = %x(#{RUTTY_BIN} -c #{TEST_CONF_DIR} -a foobar)
|
26
|
+
|
27
|
+
assert_match /^#{Colors::BOLD}#{Colors::RED}localhost#{Colors::CLEAR}\s+.*command not found.*$/, output.rstrip
|
28
|
+
end
|
29
|
+
|
30
|
+
should "display the proper output on success" do
|
31
|
+
seed_nodes
|
34
32
|
|
35
|
-
|
36
|
-
red = '\\e\[31m'
|
37
|
-
clear = '\\e\[0m'
|
33
|
+
output = %x(#{RUTTY_BIN} -c #{TEST_CONF_DIR} -a whoami)
|
38
34
|
|
39
|
-
assert_match /^#{
|
35
|
+
assert_match /^#{Colors::GREEN}localhost#{Colors::CLEAR}\s+#{ENV['USER']}$/, output.rstrip
|
40
36
|
end
|
41
37
|
|
42
|
-
should "display
|
38
|
+
should "display successful statistics output" do
|
43
39
|
seed_nodes
|
44
40
|
|
45
41
|
output = %x(#{RUTTY_BIN} -c #{TEST_CONF_DIR} -a whoami)
|
46
42
|
|
47
|
-
|
48
|
-
|
43
|
+
assert_match /\n+#{Colors::GREEN}1 host\(s\), 0 error\(s\), \d+(?:\.\d+)? seconds?#{Colors::CLEAR}/, output
|
44
|
+
end
|
45
|
+
|
46
|
+
should "display error-state statistics output" do
|
47
|
+
seed_bad_node
|
48
|
+
|
49
|
+
output = %x(#{RUTTY_BIN} -c #{TEST_CONF_DIR} -a whoami)
|
49
50
|
|
50
|
-
assert_match
|
51
|
+
assert_match /\n+#{Colors::RED}1 host\(s\), 1 error\(s\), \d+(?:\.\d+)? seconds?#{Colors::CLEAR}/, output
|
51
52
|
end
|
52
53
|
end
|
53
54
|
end
|
data/test/test_action_init.rb
CHANGED
@@ -17,10 +17,8 @@ class TestActionInit < Test::Unit::TestCase
|
|
17
17
|
ensure_fresh_config!
|
18
18
|
|
19
19
|
out = %x(#{RUTTY_BIN} init #{TEST_CONF_DIR})
|
20
|
-
|
21
|
-
|
22
|
-
clear = '\\e\[0m'
|
23
|
-
exists = "#{cyan}exists#{clear}"
|
20
|
+
|
21
|
+
exists = "#{Colors::CYAN}exists#{Colors::CLEAR}"
|
24
22
|
|
25
23
|
assert_match /^\s+#{exists}\s+#{TEST_CONF_DIR}$/o, out
|
26
24
|
assert_match /^\s+#{exists}\s+#{TEST_GENERAL_CONF}$/o, out
|
@@ -29,10 +27,8 @@ class TestActionInit < Test::Unit::TestCase
|
|
29
27
|
|
30
28
|
should "report that it has created the file structure if it doesn't exist" do
|
31
29
|
out = %x(#{RUTTY_BIN} init #{TEST_CONF_DIR})
|
32
|
-
|
33
|
-
|
34
|
-
clear = '\\e\[0m'
|
35
|
-
create = "#{green}create#{clear}"
|
30
|
+
|
31
|
+
create = "#{Colors::GREEN}create#{Colors::CLEAR}"
|
36
32
|
|
37
33
|
assert_match /^\s+#{create}\s+#{TEST_CONF_DIR}$/o, out
|
38
34
|
assert_match /^\s+#{create}\s+#{TEST_GENERAL_CONF}$/o, out
|
@@ -8,10 +8,7 @@ class TestActionListNodes < Test::Unit::TestCase
|
|
8
8
|
should "report no defined nodes when no nodes are defined" do
|
9
9
|
output = %x(#{RUTTY_BIN} list_nodes -c #{TEST_CONF_DIR} 2>&1)
|
10
10
|
|
11
|
-
|
12
|
-
clear = '\\e\[0m'
|
13
|
-
|
14
|
-
assert_match /#{yellow}No nodes defined#{clear}/, output
|
11
|
+
assert_match /#{Colors::YELLOW}No nodes defined#{Colors::CLEAR}/, output
|
15
12
|
end
|
16
13
|
|
17
14
|
should "properly list defined nodes in ASCII table format" do
|
@@ -0,0 +1,50 @@
|
|
1
|
+
require 'helper'
|
2
|
+
|
3
|
+
class TestActionSCP < Test::Unit::TestCase
|
4
|
+
context "The 'rutty scp' action" do
|
5
|
+
setup { ensure_fresh_config! }
|
6
|
+
teardown { clean_test_config! }
|
7
|
+
|
8
|
+
should "correctly upload a file to a node" do
|
9
|
+
seed_nodes
|
10
|
+
|
11
|
+
@test_file_src = File.join(File.expand_path(TMP_DIR), 'TEST')
|
12
|
+
@test_file_dest = @test_file_src.dup << "2"
|
13
|
+
|
14
|
+
File.open(@test_file_src, 'w') { |f| f.write "Hello, this is a test." }
|
15
|
+
|
16
|
+
@out = %x(#{RUTTY_BIN} scp -c #{TEST_CONF_DIR} -a #{@test_file_src} #{@test_file_dest} 2>&1)
|
17
|
+
|
18
|
+
assert_file_exists "#{@test_file_dest}"
|
19
|
+
assert_equal "Hello, this is a test.", File.read("#{@test_file_dest}")
|
20
|
+
end
|
21
|
+
|
22
|
+
should "display the correct output on success" do
|
23
|
+
seed_nodes
|
24
|
+
|
25
|
+
@test_file_src = File.join(File.expand_path(TMP_DIR), 'TEST')
|
26
|
+
@test_file_dest = @test_file_src.dup << "2"
|
27
|
+
|
28
|
+
File.open(@test_file_src, 'w') { |f| f.write "Hello, this is a test." }
|
29
|
+
|
30
|
+
@out = %x(#{RUTTY_BIN} scp -c #{TEST_CONF_DIR} -a #{@test_file_src} #{@test_file_dest} 2>&1)
|
31
|
+
|
32
|
+
assert_match /^#{Colors::GREEN}localhost#{Colors::CLEAR}\n+/, @out
|
33
|
+
assert_match /\n+#{Colors::GREEN}1 host\(s\), 0 error\(s\), \d+(?:\.\d+)? seconds?#{Colors::CLEAR}/, @out
|
34
|
+
end
|
35
|
+
|
36
|
+
should "display the correct output on error" do
|
37
|
+
seed_bad_node
|
38
|
+
|
39
|
+
@test_file_src = File.join(File.expand_path(TMP_DIR), 'TEST')
|
40
|
+
@test_file_dest = @test_file_src.dup << "2"
|
41
|
+
|
42
|
+
File.open(@test_file_src, 'w') { |f| f.write "Hello, this is a test." }
|
43
|
+
|
44
|
+
@out = %x(#{RUTTY_BIN} scp -c #{TEST_CONF_DIR} -a #{@test_file_src} #{@test_file_dest} 2>&1)
|
45
|
+
|
46
|
+
assert_match /^#{Colors::YELLOW}#{Colors::RED_BG}example\.com#{Colors::CLEAR}\s+#{Colors::RED}ERROR: Connection timeout#{Colors::CLEAR}\n+/, @out
|
47
|
+
assert_match /\n+#{Colors::RED}1 host\(s\), 1 error\(s\), \d+(?:\.\d+)? seconds?#{Colors::CLEAR}/, @out
|
48
|
+
end
|
49
|
+
end
|
50
|
+
end
|
data/test/test_node.rb
CHANGED
@@ -1,6 +1,18 @@
|
|
1
1
|
require 'helper'
|
2
2
|
|
3
3
|
class TestNode < Test::Unit::TestCase
|
4
|
+
context "The Rutty::Node class" do
|
5
|
+
should "respond to its methods" do
|
6
|
+
assert_respond_to Rutty::Node, :load_config
|
7
|
+
end
|
8
|
+
|
9
|
+
should "raise an exception on #load_config calls" do
|
10
|
+
assert_raises RuntimeError do
|
11
|
+
Rutty::Node.load_config 'foo'
|
12
|
+
end
|
13
|
+
end
|
14
|
+
end
|
15
|
+
|
4
16
|
context "A Rutty::Node instance" do
|
5
17
|
setup do
|
6
18
|
hash = { :foo => "blah", :test => "hello" }
|
@@ -12,6 +24,7 @@ class TestNode < Test::Unit::TestCase
|
|
12
24
|
node = Rutty::Node.new Hash.new, @defaults
|
13
25
|
|
14
26
|
assert_respond_to node, :has_tag?
|
27
|
+
assert_respond_to node, :==
|
15
28
|
assert_respond_to node, :<=>
|
16
29
|
end
|
17
30
|
|
data/test/test_nodes.rb
CHANGED
@@ -65,7 +65,6 @@ class TestNodes < Test::Unit::TestCase
|
|
65
65
|
|
66
66
|
should "generate the correct Proc string to eval" do
|
67
67
|
Rutty::Nodes.publicize_methods do
|
68
|
-
# New sql-like tag query. Need the parser for this.
|
69
68
|
require 'treetop'
|
70
69
|
require 'rutty/treetop/syntax_nodes'
|
71
70
|
require 'rutty/treetop/tag_query'
|
@@ -84,6 +83,16 @@ class TestNodes < Test::Unit::TestCase
|
|
84
83
|
end
|
85
84
|
end
|
86
85
|
|
86
|
+
should "raise an exception on malformed tag query strings" do
|
87
|
+
Rutty::Nodes.publicize_methods do
|
88
|
+
["'foo' ARND 'bar'", "'fail", "'failure' AND )'foo'"].each do |str|
|
89
|
+
assert_raises Rutty::InvalidTagQueryString do
|
90
|
+
@nodes.get_tag_query_filter str
|
91
|
+
end
|
92
|
+
end
|
93
|
+
end
|
94
|
+
end
|
95
|
+
|
87
96
|
should "filter out nodes matching provided criteria" do
|
88
97
|
assert_equal [@node1, @node2], @nodes.filter(OpenStruct.new :port => 22)
|
89
98
|
assert_equal [@node2], @nodes.filter(OpenStruct.new :user => 'google')
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rutty
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 31
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 2
|
8
|
-
-
|
9
|
-
-
|
10
|
-
version: 2.
|
8
|
+
- 4
|
9
|
+
- 0
|
10
|
+
version: 2.4.0
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Josh Lindsey
|
@@ -15,16 +15,158 @@ autorequire:
|
|
15
15
|
bindir: bin
|
16
16
|
cert_chain: []
|
17
17
|
|
18
|
-
date: 2010-11-
|
18
|
+
date: 2010-11-24 00:00:00 -05:00
|
19
19
|
default_executable: rutty
|
20
20
|
dependencies:
|
21
21
|
- !ruby/object:Gem::Dependency
|
22
|
-
name: bundler
|
23
|
-
prerelease: false
|
24
22
|
requirement: &id001 !ruby/object:Gem::Requirement
|
25
23
|
none: false
|
26
24
|
requirements:
|
27
|
-
- -
|
25
|
+
- - ~>
|
26
|
+
- !ruby/object:Gem::Version
|
27
|
+
hash: 57
|
28
|
+
segments:
|
29
|
+
- 4
|
30
|
+
- 0
|
31
|
+
- 3
|
32
|
+
version: 4.0.3
|
33
|
+
type: :runtime
|
34
|
+
name: commander
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: *id001
|
37
|
+
- !ruby/object:Gem::Dependency
|
38
|
+
requirement: &id002 !ruby/object:Gem::Requirement
|
39
|
+
none: false
|
40
|
+
requirements:
|
41
|
+
- - ~>
|
42
|
+
- !ruby/object:Gem::Version
|
43
|
+
hash: 3
|
44
|
+
segments:
|
45
|
+
- 1
|
46
|
+
- 4
|
47
|
+
- 2
|
48
|
+
version: 1.4.2
|
49
|
+
type: :runtime
|
50
|
+
name: terminal-table
|
51
|
+
prerelease: false
|
52
|
+
version_requirements: *id002
|
53
|
+
- !ruby/object:Gem::Dependency
|
54
|
+
requirement: &id003 !ruby/object:Gem::Requirement
|
55
|
+
none: false
|
56
|
+
requirements:
|
57
|
+
- - ~>
|
58
|
+
- !ruby/object:Gem::Version
|
59
|
+
hash: 11
|
60
|
+
segments:
|
61
|
+
- 1
|
62
|
+
- 4
|
63
|
+
- 6
|
64
|
+
version: 1.4.6
|
65
|
+
type: :runtime
|
66
|
+
name: json
|
67
|
+
prerelease: false
|
68
|
+
version_requirements: *id003
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
requirement: &id004 !ruby/object:Gem::Requirement
|
71
|
+
none: false
|
72
|
+
requirements:
|
73
|
+
- - ~>
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
hash: 33
|
76
|
+
segments:
|
77
|
+
- 2
|
78
|
+
- 0
|
79
|
+
- 23
|
80
|
+
version: 2.0.23
|
81
|
+
type: :runtime
|
82
|
+
name: net-ssh
|
83
|
+
prerelease: false
|
84
|
+
version_requirements: *id004
|
85
|
+
- !ruby/object:Gem::Dependency
|
86
|
+
requirement: &id005 !ruby/object:Gem::Requirement
|
87
|
+
none: false
|
88
|
+
requirements:
|
89
|
+
- - ~>
|
90
|
+
- !ruby/object:Gem::Version
|
91
|
+
hash: 31
|
92
|
+
segments:
|
93
|
+
- 1
|
94
|
+
- 0
|
95
|
+
- 4
|
96
|
+
version: 1.0.4
|
97
|
+
type: :runtime
|
98
|
+
name: net-scp
|
99
|
+
prerelease: false
|
100
|
+
version_requirements: *id005
|
101
|
+
- !ruby/object:Gem::Dependency
|
102
|
+
requirement: &id006 !ruby/object:Gem::Requirement
|
103
|
+
none: false
|
104
|
+
requirements:
|
105
|
+
- - ~>
|
106
|
+
- !ruby/object:Gem::Version
|
107
|
+
hash: 15
|
108
|
+
segments:
|
109
|
+
- 2
|
110
|
+
- 1
|
111
|
+
- 2
|
112
|
+
version: 2.1.2
|
113
|
+
type: :runtime
|
114
|
+
name: builder
|
115
|
+
prerelease: false
|
116
|
+
version_requirements: *id006
|
117
|
+
- !ruby/object:Gem::Dependency
|
118
|
+
requirement: &id007 !ruby/object:Gem::Requirement
|
119
|
+
none: false
|
120
|
+
requirements:
|
121
|
+
- - ~>
|
122
|
+
- !ruby/object:Gem::Version
|
123
|
+
hash: 23
|
124
|
+
segments:
|
125
|
+
- 1
|
126
|
+
- 4
|
127
|
+
- 8
|
128
|
+
version: 1.4.8
|
129
|
+
type: :runtime
|
130
|
+
name: treetop
|
131
|
+
prerelease: false
|
132
|
+
version_requirements: *id007
|
133
|
+
- !ruby/object:Gem::Dependency
|
134
|
+
requirement: &id008 !ruby/object:Gem::Requirement
|
135
|
+
none: false
|
136
|
+
requirements:
|
137
|
+
- - ~>
|
138
|
+
- !ruby/object:Gem::Version
|
139
|
+
hash: 25
|
140
|
+
segments:
|
141
|
+
- 1
|
142
|
+
- 0
|
143
|
+
- 7
|
144
|
+
version: 1.0.7
|
145
|
+
type: :runtime
|
146
|
+
name: fastthread
|
147
|
+
prerelease: false
|
148
|
+
version_requirements: *id008
|
149
|
+
- !ruby/object:Gem::Dependency
|
150
|
+
requirement: &id009 !ruby/object:Gem::Requirement
|
151
|
+
none: false
|
152
|
+
requirements:
|
153
|
+
- - ~>
|
154
|
+
- !ruby/object:Gem::Version
|
155
|
+
hash: 1
|
156
|
+
segments:
|
157
|
+
- 1
|
158
|
+
- 5
|
159
|
+
- 1
|
160
|
+
version: 1.5.1
|
161
|
+
type: :development
|
162
|
+
name: jeweler
|
163
|
+
prerelease: false
|
164
|
+
version_requirements: *id009
|
165
|
+
- !ruby/object:Gem::Dependency
|
166
|
+
requirement: &id010 !ruby/object:Gem::Requirement
|
167
|
+
none: false
|
168
|
+
requirements:
|
169
|
+
- - ~>
|
28
170
|
- !ruby/object:Gem::Version
|
29
171
|
hash: 23
|
30
172
|
segments:
|
@@ -33,27 +175,55 @@ dependencies:
|
|
33
175
|
- 0
|
34
176
|
version: 1.0.0
|
35
177
|
type: :development
|
36
|
-
|
178
|
+
name: bundler
|
179
|
+
prerelease: false
|
180
|
+
version_requirements: *id010
|
37
181
|
- !ruby/object:Gem::Dependency
|
38
|
-
|
182
|
+
requirement: &id011 !ruby/object:Gem::Requirement
|
183
|
+
none: false
|
184
|
+
requirements:
|
185
|
+
- - ">="
|
186
|
+
- !ruby/object:Gem::Version
|
187
|
+
hash: 3
|
188
|
+
segments:
|
189
|
+
- 0
|
190
|
+
version: "0"
|
191
|
+
type: :development
|
192
|
+
name: shoulda
|
39
193
|
prerelease: false
|
40
|
-
|
194
|
+
version_requirements: *id011
|
195
|
+
- !ruby/object:Gem::Dependency
|
196
|
+
requirement: &id012 !ruby/object:Gem::Requirement
|
41
197
|
none: false
|
42
198
|
requirements:
|
43
199
|
- - ">="
|
44
200
|
- !ruby/object:Gem::Version
|
45
|
-
hash:
|
201
|
+
hash: 3
|
46
202
|
segments:
|
47
|
-
- 1
|
48
|
-
- 4
|
49
203
|
- 0
|
50
|
-
version:
|
204
|
+
version: "0"
|
51
205
|
type: :development
|
52
|
-
|
206
|
+
name: rcov
|
207
|
+
prerelease: false
|
208
|
+
version_requirements: *id012
|
53
209
|
- !ruby/object:Gem::Dependency
|
54
|
-
|
210
|
+
requirement: &id013 !ruby/object:Gem::Requirement
|
211
|
+
none: false
|
212
|
+
requirements:
|
213
|
+
- - ~>
|
214
|
+
- !ruby/object:Gem::Version
|
215
|
+
hash: 15
|
216
|
+
segments:
|
217
|
+
- 1
|
218
|
+
- 0
|
219
|
+
- 12
|
220
|
+
version: 1.0.12
|
221
|
+
type: :development
|
222
|
+
name: xml-simple
|
55
223
|
prerelease: false
|
56
|
-
|
224
|
+
version_requirements: *id013
|
225
|
+
- !ruby/object:Gem::Dependency
|
226
|
+
requirement: &id014 !ruby/object:Gem::Requirement
|
57
227
|
none: false
|
58
228
|
requirements:
|
59
229
|
- - ">="
|
@@ -63,11 +233,57 @@ dependencies:
|
|
63
233
|
- 0
|
64
234
|
version: "0"
|
65
235
|
type: :development
|
66
|
-
|
236
|
+
name: ruby-debug
|
237
|
+
prerelease: false
|
238
|
+
version_requirements: *id014
|
67
239
|
- !ruby/object:Gem::Dependency
|
68
|
-
|
240
|
+
requirement: &id015 !ruby/object:Gem::Requirement
|
241
|
+
none: false
|
242
|
+
requirements:
|
243
|
+
- - ">="
|
244
|
+
- !ruby/object:Gem::Version
|
245
|
+
hash: 23
|
246
|
+
segments:
|
247
|
+
- 1
|
248
|
+
- 0
|
249
|
+
- 0
|
250
|
+
version: 1.0.0
|
251
|
+
type: :development
|
252
|
+
name: bundler
|
69
253
|
prerelease: false
|
70
|
-
|
254
|
+
version_requirements: *id015
|
255
|
+
- !ruby/object:Gem::Dependency
|
256
|
+
requirement: &id016 !ruby/object:Gem::Requirement
|
257
|
+
none: false
|
258
|
+
requirements:
|
259
|
+
- - ">="
|
260
|
+
- !ruby/object:Gem::Version
|
261
|
+
hash: 1
|
262
|
+
segments:
|
263
|
+
- 1
|
264
|
+
- 5
|
265
|
+
- 1
|
266
|
+
version: 1.5.1
|
267
|
+
type: :development
|
268
|
+
name: jeweler
|
269
|
+
prerelease: false
|
270
|
+
version_requirements: *id016
|
271
|
+
- !ruby/object:Gem::Dependency
|
272
|
+
requirement: &id017 !ruby/object:Gem::Requirement
|
273
|
+
none: false
|
274
|
+
requirements:
|
275
|
+
- - ">="
|
276
|
+
- !ruby/object:Gem::Version
|
277
|
+
hash: 3
|
278
|
+
segments:
|
279
|
+
- 0
|
280
|
+
version: "0"
|
281
|
+
type: :development
|
282
|
+
name: thoughtbot-shoulda
|
283
|
+
prerelease: false
|
284
|
+
version_requirements: *id017
|
285
|
+
- !ruby/object:Gem::Dependency
|
286
|
+
requirement: &id018 !ruby/object:Gem::Requirement
|
71
287
|
none: false
|
72
288
|
requirements:
|
73
289
|
- - ">="
|
@@ -79,11 +295,11 @@ dependencies:
|
|
79
295
|
- 12
|
80
296
|
version: 1.0.12
|
81
297
|
type: :development
|
82
|
-
|
83
|
-
- !ruby/object:Gem::Dependency
|
84
|
-
name: commander
|
298
|
+
name: xml-simple
|
85
299
|
prerelease: false
|
86
|
-
|
300
|
+
version_requirements: *id018
|
301
|
+
- !ruby/object:Gem::Dependency
|
302
|
+
requirement: &id019 !ruby/object:Gem::Requirement
|
87
303
|
none: false
|
88
304
|
requirements:
|
89
305
|
- - ">="
|
@@ -95,11 +311,11 @@ dependencies:
|
|
95
311
|
- 3
|
96
312
|
version: 4.0.3
|
97
313
|
type: :runtime
|
98
|
-
|
99
|
-
- !ruby/object:Gem::Dependency
|
100
|
-
name: terminal-table
|
314
|
+
name: commander
|
101
315
|
prerelease: false
|
102
|
-
|
316
|
+
version_requirements: *id019
|
317
|
+
- !ruby/object:Gem::Dependency
|
318
|
+
requirement: &id020 !ruby/object:Gem::Requirement
|
103
319
|
none: false
|
104
320
|
requirements:
|
105
321
|
- - ">="
|
@@ -111,11 +327,27 @@ dependencies:
|
|
111
327
|
- 2
|
112
328
|
version: 1.4.2
|
113
329
|
type: :runtime
|
114
|
-
|
330
|
+
name: terminal-table
|
331
|
+
prerelease: false
|
332
|
+
version_requirements: *id020
|
115
333
|
- !ruby/object:Gem::Dependency
|
116
|
-
|
334
|
+
requirement: &id021 !ruby/object:Gem::Requirement
|
335
|
+
none: false
|
336
|
+
requirements:
|
337
|
+
- - ">="
|
338
|
+
- !ruby/object:Gem::Version
|
339
|
+
hash: 11
|
340
|
+
segments:
|
341
|
+
- 1
|
342
|
+
- 4
|
343
|
+
- 6
|
344
|
+
version: 1.4.6
|
345
|
+
type: :runtime
|
346
|
+
name: json
|
117
347
|
prerelease: false
|
118
|
-
|
348
|
+
version_requirements: *id021
|
349
|
+
- !ruby/object:Gem::Dependency
|
350
|
+
requirement: &id022 !ruby/object:Gem::Requirement
|
119
351
|
none: false
|
120
352
|
requirements:
|
121
353
|
- - ">="
|
@@ -127,11 +359,11 @@ dependencies:
|
|
127
359
|
- 23
|
128
360
|
version: 2.0.23
|
129
361
|
type: :runtime
|
130
|
-
|
131
|
-
- !ruby/object:Gem::Dependency
|
132
|
-
name: net-scp
|
362
|
+
name: net-ssh
|
133
363
|
prerelease: false
|
134
|
-
|
364
|
+
version_requirements: *id022
|
365
|
+
- !ruby/object:Gem::Dependency
|
366
|
+
requirement: &id023 !ruby/object:Gem::Requirement
|
135
367
|
none: false
|
136
368
|
requirements:
|
137
369
|
- - ">="
|
@@ -143,11 +375,11 @@ dependencies:
|
|
143
375
|
- 4
|
144
376
|
version: 1.0.4
|
145
377
|
type: :runtime
|
146
|
-
|
147
|
-
- !ruby/object:Gem::Dependency
|
148
|
-
name: builder
|
378
|
+
name: net-scp
|
149
379
|
prerelease: false
|
150
|
-
|
380
|
+
version_requirements: *id023
|
381
|
+
- !ruby/object:Gem::Dependency
|
382
|
+
requirement: &id024 !ruby/object:Gem::Requirement
|
151
383
|
none: false
|
152
384
|
requirements:
|
153
385
|
- - ">="
|
@@ -159,11 +391,11 @@ dependencies:
|
|
159
391
|
- 2
|
160
392
|
version: 2.1.2
|
161
393
|
type: :runtime
|
162
|
-
|
163
|
-
- !ruby/object:Gem::Dependency
|
164
|
-
name: treetop
|
394
|
+
name: builder
|
165
395
|
prerelease: false
|
166
|
-
|
396
|
+
version_requirements: *id024
|
397
|
+
- !ruby/object:Gem::Dependency
|
398
|
+
requirement: &id025 !ruby/object:Gem::Requirement
|
167
399
|
none: false
|
168
400
|
requirements:
|
169
401
|
- - ">="
|
@@ -175,7 +407,25 @@ dependencies:
|
|
175
407
|
- 8
|
176
408
|
version: 1.4.8
|
177
409
|
type: :runtime
|
178
|
-
|
410
|
+
name: treetop
|
411
|
+
prerelease: false
|
412
|
+
version_requirements: *id025
|
413
|
+
- !ruby/object:Gem::Dependency
|
414
|
+
requirement: &id026 !ruby/object:Gem::Requirement
|
415
|
+
none: false
|
416
|
+
requirements:
|
417
|
+
- - ">="
|
418
|
+
- !ruby/object:Gem::Version
|
419
|
+
hash: 25
|
420
|
+
segments:
|
421
|
+
- 1
|
422
|
+
- 0
|
423
|
+
- 7
|
424
|
+
version: 1.0.7
|
425
|
+
type: :runtime
|
426
|
+
name: fastthread
|
427
|
+
prerelease: false
|
428
|
+
version_requirements: *id026
|
179
429
|
description: "\n RuTTY is a DSH (distributed / dancer's shell) written in Ruby. It's used to run commands \n on multiple remote servers at once, based on a tagging system. Also allows for multiple\n SCP-style uploads.\n "
|
180
430
|
email: josh@cloudspace.com
|
181
431
|
executables:
|
@@ -186,7 +436,6 @@ extra_rdoc_files:
|
|
186
436
|
- LICENSE
|
187
437
|
- README.md
|
188
438
|
files:
|
189
|
-
- .gitignore
|
190
439
|
- .yardopts
|
191
440
|
- Gemfile
|
192
441
|
- Gemfile.lock
|
@@ -204,6 +453,8 @@ files:
|
|
204
453
|
- lib/rutty/node.rb
|
205
454
|
- lib/rutty/nodes.rb
|
206
455
|
- lib/rutty/proc_classes.rb
|
456
|
+
- lib/rutty/thread_pool/pool.rb
|
457
|
+
- lib/rutty/thread_pool/worker.rb
|
207
458
|
- lib/rutty/treetop/syntax_nodes.rb
|
208
459
|
- lib/rutty/treetop/tag_query.rb
|
209
460
|
- lib/rutty/treetop/tag_query.treetop
|
@@ -214,6 +465,7 @@ files:
|
|
214
465
|
- test/test_action_dsh.rb
|
215
466
|
- test/test_action_init.rb
|
216
467
|
- test/test_action_list_nodes.rb
|
468
|
+
- test/test_action_scp.rb
|
217
469
|
- test/test_actions.rb
|
218
470
|
- test/test_config.rb
|
219
471
|
- test/test_consts.rb
|
@@ -223,11 +475,11 @@ files:
|
|
223
475
|
- test/test_runner.rb
|
224
476
|
has_rdoc: true
|
225
477
|
homepage: http://github.com/jlindsey/rutty
|
226
|
-
licenses:
|
227
|
-
|
478
|
+
licenses:
|
479
|
+
- MIT
|
228
480
|
post_install_message:
|
229
|
-
rdoc_options:
|
230
|
-
|
481
|
+
rdoc_options: []
|
482
|
+
|
231
483
|
require_paths:
|
232
484
|
- lib
|
233
485
|
required_ruby_version: !ruby/object:Gem::Requirement
|
@@ -261,6 +513,7 @@ test_files:
|
|
261
513
|
- test/test_action_dsh.rb
|
262
514
|
- test/test_action_init.rb
|
263
515
|
- test/test_action_list_nodes.rb
|
516
|
+
- test/test_action_scp.rb
|
264
517
|
- test/test_actions.rb
|
265
518
|
- test/test_config.rb
|
266
519
|
- test/test_consts.rb
|