awssh 0.2.2 → 0.2.3
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/awssh/command.rb +8 -3
- data/lib/awssh/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: fbcb9800f5e1861bdde7e4cab2a488ca3f881916
|
|
4
|
+
data.tar.gz: 88063803260ce7e0a79bd634e541eab5c5402348
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: a4a9c26c2d65c02c9aa8287f5394cc1941f7d9d6df8a9d9a3ced3aaf130ae2ac42a88be29110f72602a7997bb7e53f2c3c250ca232947fa52be18e401d826bc0
|
|
7
|
+
data.tar.gz: c0977a1e9491667d97ead7390eb3bb82b105f2361008054529b68ee4771b48dac80e64366d423f1a780679c87e0ae793494bef1bc79740dac6d6b58cc7ecbd49
|
data/lib/awssh/command.rb
CHANGED
|
@@ -8,6 +8,7 @@ module Awssh
|
|
|
8
8
|
multi: false,
|
|
9
9
|
test: false,
|
|
10
10
|
list: false,
|
|
11
|
+
identity: nil,
|
|
11
12
|
}
|
|
12
13
|
@config = {
|
|
13
14
|
multi: 'csshX',
|
|
@@ -41,7 +42,10 @@ module Awssh
|
|
|
41
42
|
puts "awssh version: #{Awssh::Version::STRING}"
|
|
42
43
|
exit 0
|
|
43
44
|
end
|
|
44
|
-
opts.on('-
|
|
45
|
+
opts.on('-iIDENTITY', '--identity=IDENTITY', 'set ssh key') do |i|
|
|
46
|
+
@options[:identity] = i
|
|
47
|
+
end
|
|
48
|
+
opts.on('--init', 'initialize config') do |i|
|
|
45
49
|
path = File.expand_path(@options[:config])
|
|
46
50
|
puts "creating config file: #{path}"
|
|
47
51
|
if File.exists?(path)
|
|
@@ -130,10 +134,11 @@ module Awssh
|
|
|
130
134
|
end
|
|
131
135
|
|
|
132
136
|
def command(hosts)
|
|
137
|
+
id = @options[:identity] ? "-i #{@options[:identity]}" : nil
|
|
133
138
|
if @options[:multi]
|
|
134
|
-
command = "#{@config.multi} #{hosts.map { |e| host(e) }.join(' ')}"
|
|
139
|
+
command = "#{@config.multi} #{id} #{hosts.map { |e| host(e) }.join(' ')}"
|
|
135
140
|
else
|
|
136
|
-
command = "#{@config.single} #{host(hosts.first)}"
|
|
141
|
+
command = "#{@config.single} #{id} #{host(hosts.first)}"
|
|
137
142
|
end
|
|
138
143
|
command
|
|
139
144
|
end
|
data/lib/awssh/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: awssh
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.2.
|
|
4
|
+
version: 0.2.3
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Shawn Catanzarite
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2015-
|
|
11
|
+
date: 2015-06-26 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: fog
|